Local Variable Node

Local Variables allow the storage, manipulation, and observation of a single value within a page or template. This value can be read and written by functions like any other node property, but the value itself will not be rendered to the screen. This makes local variables perfect for local state, like caches.

Local variables exist as local state within the user's browser, so changes to local variables will not be persisted upon refresh.

You can create and manage variables in the "Page State" tab in the bottom left of the Pages panel or the "Template State" tab in the bottom left of the Templates panel in the editor .

Local variables can be likened to "lifted" state in reactive systems.

Properties

Value

ProplocalVariableNode.value
Typeunknown
Default{{null}}

The stored value of this variable.