Designer API
Control the Webflow Designer
collection.getName()
Retrieves the name of the variable collection.
1collection.getName(): Promise<string>
Promise< string>
string
A Promise that resolves to a string of the Variable Collection’s name
1// Get Collection2const defaultVariableCollection = await webflow.getDefaultVariableCollection();34// Get Collection Name5const collectionName = await defaultVariableCollection?.getName()6console.log(collectionName)
Try this example
Checks for Authorization only