| 12345678910111213141516171819202122232425262728 |
- /*
- * @Author: Gaoxs
- * @Date: 2023-04-07 15:12:06
- * @LastEditors: Gaoxs
- * @Description:
- */
- import util from '@/utils'
- import App from './App'
- import { createPinia } from 'pinia'
- import { createPersistedState } from 'pinia-plugin-persistedstate'
- import { createSSRApp } from 'vue'
- export function createApp() {
- const app = createSSRApp(App)
- app.use(util)
- //app.use(createPinia())
- const pinia = createPinia()
- pinia.use(createPersistedState({ storage: {getItem: uni.getStorageSync,setItem: uni.setStorageSync}}))
- app.use(pinia)
- return {
- app,
- pinia
- }
- }
|