mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
Merge branch 'master' of gitlab.qima-inc.com:fe/zanui-vue
This commit is contained in:
commit
b207efe729
@ -9,6 +9,7 @@ var getPoastcssPlugin = require('./utils/postcss_pipe');
|
||||
var ProgressBarPlugin = require('progress-bar-webpack-plugin');
|
||||
var ExtractTextPlugin = require('extract-text-webpack-plugin');
|
||||
var HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||
var OptimizeCssAssetsPlugin = require('optimize-css-assets-webpack-plugin');
|
||||
|
||||
var StyleExtractPlugin;
|
||||
if (process.env.NODE_ENV === 'production') {
|
||||
@ -160,6 +161,7 @@ module.exports = {
|
||||
filename: 'examples.html',
|
||||
inject: true
|
||||
}),
|
||||
new OptimizeCssAssetsPlugin(),
|
||||
StyleExtractPlugin
|
||||
]
|
||||
};
|
||||
|
@ -3,7 +3,7 @@ import VueRouter from 'vue-router';
|
||||
import App from './ExamplesApp';
|
||||
import navConfig from './nav.config.js';
|
||||
import routes from './router.config';
|
||||
import ZanUI from '../src/index';
|
||||
import ZanUI from 'src/index';
|
||||
|
||||
import 'packages/zanui-css/src/index.css';
|
||||
|
||||
|
@ -26,7 +26,6 @@ Vue.use(ZanUI.Lazyload, {
|
||||
lazyComponent: true
|
||||
});
|
||||
|
||||
|
||||
let routesConfig = routes(navConfig);
|
||||
routesConfig.push({
|
||||
path: '/',
|
||||
@ -44,9 +43,9 @@ router.beforeEach((route, redirect, next) => {
|
||||
window.scrollTo(0, 0);
|
||||
}
|
||||
|
||||
const pathname = process.env.NODE_ENV === 'production' ? '/vue/' : '/';
|
||||
const pathname = process.env.NODE_ENV === 'production' ? '/vue/examples' : '/examples.html';
|
||||
if (isMobile()) {
|
||||
window.location.replace(pathname + 'examples.html#/');
|
||||
window.location.replace(pathname);
|
||||
return;
|
||||
}
|
||||
document.title = route.meta.title || document.title;
|
||||
|
@ -104,6 +104,7 @@
|
||||
"markdown-it-anchor": "^2.5.0",
|
||||
"markdown-it-container": "^2.0.0",
|
||||
"mocha": "^3.2.0",
|
||||
"optimize-css-assets-webpack-plugin": "^1.3.0",
|
||||
"postcss": "^5.1.2",
|
||||
"postcss-easy-import": "^2.0.0",
|
||||
"postcss-loader": "^1.3.3",
|
||||
|
Loading…
x
Reference in New Issue
Block a user