Menu

Vue product tour: add one to Vue and Nuxt apps
📰

Vue product tour: add one to Vue and Nuxt apps

DEV Community: vue·JustOneCX·3 days ago
#6JyA0zQI
#devtovue#devto#dev#init#tour
Long article (1072 words) — no AI summary yet.
Reading 0:00
15s threshold

To add a product tour to a Vue app, install @justonecx/sdk and call init() in main.ts after app.mount() . In Nuxt, put the call in a plugin named plugins/justonecx.client.ts . The .client suffix keeps it out of server rendering. Pass trackRouteChanges: true so tours follow your router.

What do you need?

Your public key (starts with pk_ ) from Settings, Developers .

Your site's origin in Settings, Developers, Domains & CORS . For local work add your dev origin, for example http://localhost:3000 .

The package: npm install @justonecx/sdk . If you prefer, use the script tag from the quickstart instead.

What rules apply in every framework?

Call init() once, in the browser only, after the app mounts.

In single-page apps, pass trackRouteChanges: true .…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.