Skip to content

Asynchronous initialization and data recovery #2917

Closed Answered by posva
hzdjulytech asked this question in Help and Questions
Discussion options

You must be logged in to vote

Mount the app after the init is done:

const app = createApp()
app.use(pinia)
await useUserStore(pinia).init()
app.mount()

This can also be done within App.vue or with a boolean that toggles the Root <RouterViev>

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by posva
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants