36 lines
898 B
TypeScript
36 lines
898 B
TypeScript
|
import { createSSRApp } from "vue";
|
|||
|
import uviewPlus from "uview-plus";
|
|||
|
import pinia from './store'
|
|||
|
import App from "./App.vue";
|
|||
|
import './static/style/common.scss'
|
|||
|
|
|||
|
import TabBar from "@/components/TabBar/index.vue"//路径根据你的文件修改
|
|||
|
|
|||
|
export function createApp() {
|
|||
|
const app = createSSRApp(App);
|
|||
|
app.use(uviewPlus);
|
|||
|
app.use(pinia);
|
|||
|
app.component('TabBar', TabBar)
|
|||
|
|
|||
|
uni.$u.setConfig({
|
|||
|
// 修改$u.config对象的属性
|
|||
|
config: {
|
|||
|
// 修改默认单位为rpx,相当于执行 uni.$u.config.unit = 'rpx'
|
|||
|
unit: 'px'
|
|||
|
},
|
|||
|
// 修改$u.props对象的属性
|
|||
|
props: {
|
|||
|
// 修改radio组件的size参数的默认值,相当于执行 uni.$u.props.radio.size = 30
|
|||
|
// checkbox: {
|
|||
|
// size: 15
|
|||
|
// }
|
|||
|
// 其他组件属性配置
|
|||
|
// ......
|
|||
|
}
|
|||
|
})
|
|||
|
return {
|
|||
|
app,
|
|||
|
pinia
|
|||
|
};
|
|||
|
}
|