|
|
@@ -1,22 +1,22 @@
|
|
|
-import App from "./App";
|
|
|
-import Vue from "vue";
|
|
|
-import VHtmlPlugin from "@megalo/vhtml-plugin";
|
|
|
-import Vuex from "vuex";
|
|
|
-import http from "./plugins/http";
|
|
|
+import App from './App';
|
|
|
+import Vue from 'vue';
|
|
|
+import VHtmlPlugin from '@megalo/vhtml-plugin';
|
|
|
+import Vuex from 'vuex';
|
|
|
+import http from './plugins/http';
|
|
|
// import Dialog from "./vant/dialog/dialog";
|
|
|
-import common from "./mixins/common";
|
|
|
-import "./styles/font.less";
|
|
|
-import "./styles/vanIndex.less";
|
|
|
+import common from './mixins/common';
|
|
|
+import './styles/font.less';
|
|
|
+import './styles/vanIndex.less';
|
|
|
|
|
|
Vue.prototype.$colors = {
|
|
|
- prim: "#FF7F1F",
|
|
|
- red: "#F42202"
|
|
|
+ prim: '#FF7F1F',
|
|
|
+ red: '#F42202'
|
|
|
};
|
|
|
|
|
|
Vue.use(VHtmlPlugin);
|
|
|
Vue.use(Vuex);
|
|
|
|
|
|
-const store = require("./store").default;
|
|
|
+const store = require('./store').default;
|
|
|
Vue.prototype.$store = store;
|
|
|
Vue.use(http);
|
|
|
const app = new Vue(App);
|
|
|
@@ -24,70 +24,70 @@ Vue.mixin(common);
|
|
|
app.$mount();
|
|
|
|
|
|
export default {
|
|
|
- config: {
|
|
|
- // pages 的首个页面会被编译成首页
|
|
|
- pages: ["pages/news", "pages/vuex/vuex", "pages/Home"],
|
|
|
- tabBar: {
|
|
|
- color: "#333",
|
|
|
- selectedColor: "#007d37",
|
|
|
- list: [
|
|
|
- {
|
|
|
- pagePath: "pages/Home",
|
|
|
- text: "home",
|
|
|
- iconPath: "native/tabbar/home.png",
|
|
|
- selectedIconPath: "native/tabbar/home_on.png"
|
|
|
+ config: {
|
|
|
+ // pages 的首个页面会被编译成首页
|
|
|
+ pages: ['pages/news', 'pages/vuex/vuex', 'pages/Home'],
|
|
|
+ tabBar: {
|
|
|
+ color: '#333',
|
|
|
+ selectedColor: '#007d37',
|
|
|
+ list: [
|
|
|
+ {
|
|
|
+ pagePath: 'pages/Home',
|
|
|
+ text: 'home',
|
|
|
+ iconPath: 'native/tabbar/home.png',
|
|
|
+ selectedIconPath: 'native/tabbar/home_on.png'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ pagePath: 'pages/news',
|
|
|
+ text: 'news',
|
|
|
+ iconPath: 'native/tabbar/mine.png',
|
|
|
+ selectedIconPath: 'native/tabbar/mine_on.png'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ pagePath: 'pages/vuex/vuex',
|
|
|
+ text: 'vuex',
|
|
|
+ iconPath: 'native/tabbar/vue.png',
|
|
|
+ selectedIconPath: 'native/tabbar/vue_on.png'
|
|
|
+ }
|
|
|
+ ]
|
|
|
},
|
|
|
- {
|
|
|
- pagePath: "pages/news",
|
|
|
- text: "news",
|
|
|
- iconPath: "native/tabbar/mine.png",
|
|
|
- selectedIconPath: "native/tabbar/mine_on.png"
|
|
|
+ usingComponents: {
|
|
|
+ 'van-image': '/vant/image/index',
|
|
|
+ 'van-button': '/vant/button/index',
|
|
|
+ 'van-tabs': '/vant/tabs/index',
|
|
|
+ 'van-tab': '/vant/tab/index',
|
|
|
+ 'van-notice-bar': '/vant/notice-bar/index',
|
|
|
+ 'van-icon': '/vant/icon/index',
|
|
|
+ 'van-grid-item ': '/vant/grid-item/index',
|
|
|
+ 'van-count-down': '/vant/count-down/index',
|
|
|
+ 'van-dialog': '/vant/dialog/index',
|
|
|
+ 'van-search': '/vant/search/index',
|
|
|
+ 'van-empty': '/vant/empty/index',
|
|
|
+ 'van-sticky': '/vant/sticky/index',
|
|
|
+ 'van-loading': '/vant/loading/index',
|
|
|
+ 'van-action-sheet': '/vant/action-sheet/index',
|
|
|
+ 'van-picker': '/vant/picker/index',
|
|
|
+ 'van-cell-group': '/vant/cell-group/index',
|
|
|
+ 'van-cell': '/vant/cell/index',
|
|
|
+ 'van-field': '/vant/field/index',
|
|
|
+ 'van-uploader': '/vant/uploader/index',
|
|
|
+ 'van-checkbox': '/vant/checkbox/index',
|
|
|
+ 'van-panel': '/vant/panel/index',
|
|
|
+ 'van-overlay': '/vant/overlay/index',
|
|
|
+ 'van-stepper': '/vant/stepper/index',
|
|
|
+ 'van-steps': '/vant/steps/index',
|
|
|
+ 'van-rate': '/vant/rate/index',
|
|
|
+ 'van-popup': '/vant/popup/index',
|
|
|
+ 'van-area': '/vant/area/index',
|
|
|
+ 'van-goods-action': 'vant/goods-action/index',
|
|
|
+ 'van-goods-action-icon': 'vant/goods-action-icon/index',
|
|
|
+ 'van-goods-action-button': 'vant/goods-action-button/index',
|
|
|
+ 'van-calendar': 'vant/calendar/index'
|
|
|
},
|
|
|
- {
|
|
|
- pagePath: "pages/vuex/vuex",
|
|
|
- text: "vuex",
|
|
|
- iconPath: "native/tabbar/vue.png",
|
|
|
- selectedIconPath: "native/tabbar/vue_on.png"
|
|
|
+ window: {
|
|
|
+ backgroundTextStyle: 'light',
|
|
|
+ navigationBarBackgroundColor: '#fff',
|
|
|
+ navigationBarTextStyle: 'black'
|
|
|
}
|
|
|
- ]
|
|
|
- },
|
|
|
- usingComponents: {
|
|
|
- "van-image": "/vant/image/index",
|
|
|
- "van-button": "/vant/button/index",
|
|
|
- "van-tabs": "/vant/tabs/index",
|
|
|
- "van-tab": "/vant/tab/index",
|
|
|
- "van-notice-bar": "/vant/notice-bar/index",
|
|
|
- "van-icon": "/vant/icon/index",
|
|
|
- "van-grid-item ": "/vant/grid-item/index",
|
|
|
- "van-count-down": "/vant/count-down/index",
|
|
|
- "van-dialog": "/vant/dialog/index",
|
|
|
- "van-search": "/vant/search/index",
|
|
|
- "van-empty": "/vant/empty/index",
|
|
|
- "van-sticky": "/vant/sticky/index",
|
|
|
- "van-loading": "/vant/loading/index",
|
|
|
- "van-action-sheet": "/vant/action-sheet/index",
|
|
|
- "van-picker": "/vant/picker/index",
|
|
|
- "van-cell-group": "/vant/cell-group/index",
|
|
|
- "van-cell": "/vant/cell/index",
|
|
|
- "van-field": "/vant/field/index",
|
|
|
- "van-uploader": "/vant/uploader/index",
|
|
|
- "van-checkbox": "/vant/checkbox/index",
|
|
|
- "van-panel": "/vant/panel/index",
|
|
|
- "van-overlay": "/vant/overlay/index",
|
|
|
- "van-stepper": "/vant/stepper/index",
|
|
|
- "van-steps": "/vant/steps/index",
|
|
|
- "van-rate": "/vant/rate/index",
|
|
|
- "van-popup": "/vant/popup/index",
|
|
|
- "van-area": "/vant/area/index",
|
|
|
- "van-goods-action": "vant/goods-action/index",
|
|
|
- "van-goods-action-icon": "vant/goods-action-icon/index",
|
|
|
- "van-goods-action-button": "vant/goods-action-button/index",
|
|
|
- "van-calendar": "vant/calendar/index"
|
|
|
- },
|
|
|
- window: {
|
|
|
- backgroundTextStyle: "light",
|
|
|
- navigationBarBackgroundColor: "#fff",
|
|
|
- navigationBarTextStyle: "black"
|
|
|
}
|
|
|
- }
|
|
|
};
|