shakee93 / vue-toasted

🖖 Responsive Touch Compatible Toast plugin for VueJS 2+
https://shakee93.github.io/vue-toasted/
MIT License
2.21k stars 194 forks source link

[webpack] Any way to extract vue-toasted CSS? #137

Open ghost opened 5 years ago

ghost commented 5 years ago

I am using nuxt.js and I have disabled inline CSS through the CSP header for security reasons and I have set extractCSS: true in my nuxt.config.js to extract styles but it doesn't extract the CSS of vue-toasted despite working with my other plugins.

Is there any way to achieve that through the webpack config?

Reproduction steps:

git clone https://github.com/vinyle-twt/nuxt-toasted
cd nuxt-toasted
npm i
npm run build
npm run start

You will see a <style> tag in the DOM with vue-toasted CSS inside.

shakee93 commented 4 years ago

https://github.com/shakee93/vue-toasted/blob/master/src/toast.vue this is how we load the styles

hmaesta commented 4 years ago

Still not clear for me... How to remove styles? I am using Nuxt integration.

rafalolszewski94 commented 3 years ago

Still not clear for me... How to remove styles? I am using Nuxt integration.

Also looking for a way to not double the styles in the bundle.