We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 935c27e commit 7562737Copy full SHA for 7562737
index.js
@@ -1,16 +1,14 @@
1
const VueAutoRoutingPlugin = require('vue-auto-routing/lib/webpack-plugin')
2
3
-module.exports = (api, options) => {
4
- const opts =
5
- (options.pluginOptions && options.pluginOptions.autoRouting) || {}
+const defaultOptions = {
+ pages: 'src/pages',
+ nested: true,
6
+}
7
8
+module.exports = (api, options) => {
9
const pluginOptions = {
- pages: 'src/pages',
- nested: true
10
- }
11
-
12
- if (opts.chunkNamePrefix != null) {
13
- pluginOptions.chunkNamePrefix = opts.chunkNamePrefix
+ ...defaultOptions,
+ ...(options.pluginOptions && options.pluginOptions.autoRouting),
14
}
15
16
api.chainWebpack(webpackConfig => {
0 commit comments