Innologica / vue2-daterange-picker

Vue2 date range picker
https://innologica.github.io/vue2-daterange-picker/
MIT License
329 stars 208 forks source link

CSS styles are lost in production mode #305

Open ghost opened 2 years ago

ghost commented 2 years ago

Hello! I have the following problem: in production mode css styles are not applied. In development mode everything is ok. I guess it happens because of Purgecss plugin, which we have only on production. I tried adding some daterange-picker classes to whitelistPatterns, but it didn't help.

Here is how daterange-picker looks on prod: image

Here is my styles import (as described in the docs) image

Here is postcss.config image

d0hn commented 2 years ago

Have you tried to use safelisting in the actual css/scss? Like so:

/* purgecss start ignore */
@import "~vue2-daterange-picker/dist/vue2-daterange-picker.css";
/* purgecss end ignore */