/*
 * @Author: wjc
 * @Date: 2024-05-27 11:49:45
 * @LastEditors: wjc
 * @LastEditTime: 2024-06-12 11:20:09
 * @Description:
 */
import { createSSRApp } from 'vue'
import * as Pinia from 'pinia'
import uviewPlus from 'uview-plus'
import 'virtual:uno.css'
import { setupStores } from '@/stores'
import { setupInterceptor } from '@/utils/request'
import '@/static/styles/vars.scss'
import '@/static/styles/index.scss'

import App from './App.vue'

export function createApp() {
  const app = createSSRApp(App)

  app.use(uviewPlus)
  setupStores(app)
  setupInterceptor(app)

  return {
    app,
    Pinia,
  }
}
