You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
418 B
18 lines
418 B
|
2 months ago
|
import { createSSRApp } from 'vue'
|
||
|
|
import uviewPlus from 'uview-plus'
|
||
|
|
import App from './App.vue'
|
||
|
|
import { setupStore } from './stores'
|
||
|
|
import { useUserStore } from './stores/user'
|
||
|
|
|
||
|
|
export function createApp() {
|
||
|
|
const app = createSSRApp(App)
|
||
|
|
const pinia = setupStore()
|
||
|
|
app.use(pinia)
|
||
|
|
app.use(uviewPlus)
|
||
|
|
const userStore = useUserStore(pinia)
|
||
|
|
userStore.bootstrap()
|
||
|
|
return {
|
||
|
|
app,
|
||
|
|
}
|
||
|
|
}
|