Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to add third party package to content? #188

Open
liborjelinek opened this issue Oct 3, 2023 · 0 comments
Open

How to add third party package to content? #188

liborjelinek opened this issue Oct 3, 2023 · 0 comments

Comments

@liborjelinek
Copy link

Despite the docs mention to Don't forget to add paths to pages and components that are not part the common folders (e.g. third party packages), I don't know where and how :-)

I am trying to purge unused styles from PrimeVue and PrimeFlex libraries it if matters.

In default state, nuxt-purgecss deletes almost everything. I suppose I need to append PrimeVue and PrimeFlex packages to PurgeCSS content settings...

I tried in the nuxt.config.ts

modules: [
    "@vueuse/nuxt",
    "@nuxt/content",
    "nuxt-simple-sitemap",
    ["nuxt-purgecss", {
       content: ["...???..."]
     }],
  ],

almost everything instead of ...???..., e.g. node_modules/primevue/**/*.{vue,jsx?,tsx?}, primevue/**/*.{vue,jsx?,tsx?}, etc.

Safelisting is not an option, because PrimeFlex nor PrimeVue has no common CSS classes prefix like Vuetify, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant