Open MikaelEdebro opened 6 years ago
see https://github.com/vuejs/rollup-plugin-vue/issues/201
maybe you're using rollup-plugin-vue@4, try this flag --no-vue.css
to make it work.
So, how could I extract CSS from components if I use rollup-plugin-vue@4?
@hiendv hope this link may be helpful for you: https://rollup-plugin-vue.vuejs.org/options.html#css, which works for me.
my bili.config.js
is as follows:
"rollup-plugin-vue": "^4.7.2", "bili": "^3.4.0",
const vue = require('rollup-plugin-vue');
module.exports = {
name: 'fe-vue-components',
format: [
'cjs',
'es',
'umd',
'umd-min',
],
compress: 'umd',
plugins: [
vue({
css: false,
}),
],
};
I upgraded bili to latest version (3.0.13), to get access to the new
config
CLI argument. However, now I notice that it no longer respects the--vue.css dist/styles.css
. Instead it names the css bundle with the same name as the js.My npm script:
bili --format cjs,es,umd,umd-min --plugin vue --vue.css dist/styles.css
Also, before when
--vue.css
was working as expected, it only created a unminified styles.css. Is there a flag for the rollup-plugin-vue to get minified output?