@@ -13,6 +13,8 @@ const routes = [
];
const router = new VueRouter({
+ mode: 'history',
+ base: process.env.NODE_ENV === 'development' ? '' : 'examine',
routes,
});
@@ -1,6 +1,7 @@
const path = require('path');
module.exports = {
- publicPath: '/',
+ publicPath: process.env.NODE_ENV === 'development' ? '/' : 'examine',
+ outputDir: 'examine',
configureWebpack: config => {
Object.assign(config, {
// 开发生产共同配置