Roots Discourse

How to purgecss a secondary css apart from the main tailwind one (Sage 10)

Hello,

I splitted a css file for specific pages, and I want to purge it the same way as tailwind does. But I don’t know how to start as Tailwind has a very complicated process of doing so with its layers.

Has someone experience with this?

This is the line of code I think has to be modified in webpack.mix.js:

mix
  .sass('resources/styles/app.scss', 'styles')
  .sass('resources/styles/plyr.scss', 'styles') // <--- this is the file I want to purge
  .sass('resources/styles/editor.scss', 'styles')
  .options({
    processCssUrls: false,
    postCss: [require('tailwindcss')],
  });