1 Star 0 Fork 1.2K

Axl Zhao / lilishop商城-移动端(小程序-H5-APP-公众号)

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
main.js 1.24 KB
一键复制 编辑 原始数据 按行查看 历史
Yer11214 提交于 2022-08-25 18:25 . 优化小程序分享
import Vue from "vue";
import App from "./App";
import * as filters from "./utils/filters.js"; // global filter
import uView from "uview-ui";
import store from "./store";
/**
* 仅在h5中显示唤醒app功能
* 在h5页面手动挂载
*
*/
// #ifdef H5
import airBtn from "@/components/m-airbtn/index.vue";
let btn = Vue.component("airBtn", airBtn); //全局注册
document.body.appendChild(new btn().$mount().$el);
// #endif
// 引入uView对小程序分享的mixin封装
let mpShare = require('uview-ui/libs/mixin/mpShare.js');
Vue.mixin(mpShare)
/**
* 全局filters
*/
Object.keys(filters).forEach((key) => {
Vue.filter(key, filters[key]);
});
// 引入Vuex
Vue.prototype.$store = store;
Vue.use(uView);
Vue.config.productionTip = false;
/**
* 注意!
* 此处将常用的颜色嵌入到原型链上面
* 颜色使用驼峰命名对应 uni.scss中全局颜色变量名
* 如需更换主题请修改此处以及uni.scss中的全局颜色
*/
// 主题色
Vue.prototype.$mainColor = "#ff3c2a";
// 高亮主题色
Vue.prototype.$lightColor = "#ff6b35";
// 辅助高亮颜色
Vue.prototype.$aiderLightColor = "#ff9f28";
App.mpType = "app";
const app = new Vue({
...App,
});
app.$mount();
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/sarins/lilishop-uniapp.git
git@gitee.com:sarins/lilishop-uniapp.git
sarins
lilishop-uniapp
lilishop商城-移动端(小程序-H5-APP-公众号)
master

搜索帮助

344bd9b3 5694891 D2dac590 5694891