Home > blockly > serialization > variables > VariableSerializer > save
serialization.variables.VariableSerializer.save() method
Serializes the variables of the given workspace.
Signature:
save(workspace: Workspace): IVariableState[] | null;
Parameters
| Parameter | Type | Description |
|---|---|---|
| workspace | Workspace | The workspace to save the variables of. |
Returns:
IVariableState[] | null
The state of the workspace's variables, or null if there are no variables.