Types of Variables
This documentation is about setting variables on the current frame, tab, or browser session.
If you need to store data that are accessible to multiple team members, or across browser profiles, see PixieBrix’s Team Databases feature
Variable Type Summary
Variables in PixieBrix work similarly to variable in other Low-Code Application Platforms and programming languages.
There are two special variable types made available by PixieBrix for providing configuration and starter brick run context: Mod Options and Starter Brick Input Variables.
Local Variable
Varies: the variable name is configured via the "Output Variable" for a brick
Available to all bricks after the brick at the same, or deeper nested level
Output from a Brick
Mod Variable
@mod
Available to all non-starter bricks in the Mod Can be configured to be automatically synchronized across frames/tabs. See Mod Variable Synchronization Policy
Mod Variable Bricks: Assign Mod Variable, Run with Async Mod Variable, Run with Cache
Advanced Bricks: Set Shared Page State
Mod Option
@options
Declared in the "Input Form" in the Page Editor Available to all bricks in a Mod
Read-only within a Mod Configured when Activating a Mod Configured when Deploying a Mod. See Deploying Mods
Starter Brick Input Variable
@input
Available to all bricks in a Mod Component
Read-only within a Mod Automatically, when the Starter Brick runs
Advanced: Shared Page State
Page State has been superseded by Mod Variables for working with mod-scoped data. Mod Variables are easy to reference via @mod , and enable PixieBrix to apply automatic performance optimizations
Page State is in-memory storage used to: 1) persist information across starter brick runs, 2) share data between mod components and/or mods. For detailed information on using Page State, see Advanced: Using Page State
There are two primary built-in bricks for working with Page State:
Get shared page state
Set shared page state
Page State can be assigned to 3 available namespaces:
Private: visible only to bricks within a single Mod Component
Mod: visible to all bricks in a single Mod
Public: visible to all Mods
Last updated
Was this helpful?