Add Self-hosted Dashboard Modal Extensions

The dashboard modal extension lets you import a modal that you built and are hosting externally into your app. You can manage the modal in your app using the openModal() and closeModal() functions from the dashboard SDK or from useDashboard() in the dashboard-react SDK.

Note: For a more streamlined approach to developing your dashboard modal, try out the Wix CLI instead of self-hosting.

Follow these steps and you'll be ready to add a dashboard modal to your self-hosted apps.

Before you begin

Before implementing a dashboard modal extension you need to:

  • Build and host your modal externally.
  • Make sure there are no restrictions on how you build your modal.
  • Have the URL that hosts your modal ready.

Add a dashboard modal to your app

  1. In the Wix Dev Center, navigate to My Apps, and then click on your app.

  2. Go to the Extensions page, and click + Create Extension.

  3. Search for the dashboard modal. Then click + Create.

  4. Add your modal's details in the JSON editor. This is where you provide the extension with the details it needs to render your modal in your app. This includes the URL that hosts your modal, size, and names. Use the Documentation tab on the right hand side of the JSON editor to help you.

    Important: The hosting platform must be "BUSINESS_MANAGER".

    For example:

    Copy
    1
  5. Now that your dashboard modal extension is set up, you can open and close it in your app using the openModal() and closeModal() SDK functions. You'll need your modal's component ID. You can find the component ID by opening your extension in the Dev Center and checking the URL at the top of your browser.

    For example:

Was this helpful?
Yes
No