webpack打包的时候,被拆分的文件怎么命名
发布于 7 年前 作者 wtcsy 3248 次浏览 来自 问答

这是routes.js import Vue from ‘vue’; import Router from ‘vue-router’; import index from ‘./index.vue’; let notFound = resolve => require([’./notFound.vue’], resolve); let swipe = resolve => require([’./swipe.vue’], resolve); //let notFound = resolve => require([’./notFound.vue’], “notFound”); //let swipe = resolve => require([’./swipe.vue’], “swipe”); Vue.use(Router); export default new Router({ routes: [ { path : ‘’, component: index }, { path : ‘/swipe’, component: swipe }, { path : ‘*’, component: notFound },
] });

上面异步加载的js 打包出来是 0.js 1.js 我怎么才能打包出来notFound.js swipe.js 因为这样才方便看

回到顶部