Get variable mode by ID
collection.getVariableModeById(string: modeId)
Get a variable mode by its ID.
Syntax
Parameters
- modeId: string - The ID of the variable mode to get. Pass the reserved ID
"base"to get the collection’s base mode.
Returns
Promise<VariableMode> A Promise that resolves to a variable mode object.
Example
"base" is a reserved mode ID. Passing it returns the collection’s base mode — the default mode every variable falls back to. The base mode’s ID stays "base" even when its display name is customized, so this is a reliable way to fetch it without first looking it up by name.