page.getSlug()

Get the slug of the page.

Syntax

1page.getSlug(): Promise<string>

Returns

Promise<string>

A promise that resolves to the slug of the page.

Example

1// Get Current Page
2const currentPage = await webflow.getCurrentPage() as Page
3
4// Get page slug
5const pageSlug = await currentPage.getSlug()
6console.log(pageSlug)

Designer Ability

Designer AbilityLocaleBranchWorkflowSitemode
canReadPageSettingsAnyAnyAnyAny
Built with