I'm generating a library with Vue CLI 4.4:
vue-cli-service build --target lib --formats=umd,umd-min --name example main.js
As a result, I get a number of files in the dist folder:
example.umd.js
example.umd.min.js
I'd like to remove the .umd from the file name. How to accomplish that?
.umd
I've tried the following two things in my vue.config.js, but it did not help:
vue.config.js
configureWebpack: { output: { filename: 'example.js', chunkFilename: 'example.[name].js' } }
chainWebpack: config => { config.output.filename('example.js') config.output.chunkFilename('example.[name].js') }
It seems vue-cli sets this "postfix" here: https://github.com/vuejs/vue-cli/blob/dev/packages/%40vue/cli-service/lib/commands/build/resolveLibConfig.js#L140 Unfortunately, I can't figure out how to override it without forking the whole project.
1.4m articles
1.4m replys
5 comments
57.0k users