To get variable modes for a node:
node.explicitVariableModes
To set variable mode for a node:
To get a variable collection:
figma.variables.getVariableCollectionById(collectionId)
To get variable modes for a node:
node.explicitVariableModes
To set variable mode for a node:
To get a variable collection:
figma.variables.getVariableCollectionById(collectionId)