Dashboard Page Extension Files and Code

When you generate a dashboard page extension, the CLI adds the following files to your project:

  • <your-page-name>.extension.ts: Builds the page.
  • <your-page-name>.tsx: Defines the page content.

Page builder

The <your-page-name>.extension.ts file contains a dashboard page's builder configuration.

The page builder is defined using the following schema, shown here as a TypeScript type:

Copy

Here's an example builder definition:

Copy

Builder fields

The following fields can be used in the configuration object:

FieldTypeDescription
idstringPage ID as a (GUID). It must be unique across all pages in the project.
titlestringThe page title. The title is used as the browser tab title and as the dashboard sidebar label if the page is configured to appear in the sidebar.
routePathstringRoute that lead to this page. Use this route in code to reference the page.
componentstringA route to the page content component.
priority (optional)numberOrder of this page in the dashboard sidebar when the project has multiple dashboard pages. Smaller numbers appear higher in the list.

When your project has more than 1 dashboard page, set priority on each extensions.dashboardPage() so the dashboard sidebar lists the pages in the order you want. Smaller numbers appear higher in the list.

Set priority in each page's <your-page-name>.extension.ts file. For example, for a project with a Settings page and a Reports page:

Copy
Copy

Both pages must be registered in src/extensions.ts. The CLI adds that registration when it generates the extension.

After you change priorities, build and release your project so the updated sidebar order is registered. See Build and Deploy with the CLI.

Note: This priority controls the order of dashboard pages in the dashboard sidebar. It isn't the same as the toast priority in the Dashboard SDK, which accepts low, normal, or high.

If you're migrating from the legacy Wix CLI for Headless, copy the page's compData.backOfficePage.sidebar.priority value from the page's extension.json to the builder's priority field.

Page content

The <your-page-name>.tsx file contains a dashboard page's content.

The content is defined as a React component that renders when the page is active.

Inside a dashboard page component you can use:

Last updated: 15 October 2026

Did this help?