Questions tagged [css-purge]

A CSS tool written in Node JS as a command line app or library for the purging, burning, reducing, shortening, compressing, cleaning, trimming and formatting of duplicate, extra, excess or bloated CSS.

More information here: https://www.npmjs.com/package/css-purge

90 questions
0
votes
2 answers

Angular 11.2^ + Tailwind + NX - Buld slow and freezing when purge enabled

If you have multiple applications in an NX Workspace and you are using TaiwindCSS you might have slow builds or build will be stuck when purge is enabled. Since Angular 11.2, Tailwindcss now work out of the box. but purging is still not smooth…
Sivuyile TG Magutywa
  • 1,041
  • 12
  • 15
0
votes
0 answers

Tailwind Custom Purge Regex?

I'm trying to figure out how to implement a custom regex pattern for purging my tailwind project. The issue is that I am not using HTML elements at all, rather, I have created a PHP framework package that uses PHP functions to build HTML. Here is an…
kjdion84
  • 9,552
  • 8
  • 60
  • 87
0
votes
1 answer

usage of purgecss safelist option gives UnhandledPromiseRejectionWarning

I'm using purgecss to remove unnecessary css from my project. purgecss --css static/css/*.chunk.css --content index.html static/js/*.chunk.js --output static/css/ But unfortunately it also removes some css classes that I need so referring the docs…
KANE
  • 63
  • 1
  • 1
  • 11
0
votes
2 answers

SCSS style got purged with @nuxtjs/tailwindcss

I've got a nuxt project where I use @nuxtjs/tailwindcss and vue-formulate. I've declared a few styles for vue-formulate in a scss file and it works great when I do nuxt --spa but when I try to generate the project using nuxt generate and serve it,…
Yunan
  • 43
  • 1
  • 1
  • 6
0
votes
1 answer

How to enable PurgeCSS for 3rd-part CSS

I am using @mdi/font in my SSR Nuxt project. How can I enable purgeCSS for CSS from @mdi/font? nuxt.config.js module.exports = { css: [ '@/assets/scss/app.scss' ], ... } assets/scss/app.scss @import…
DengSihan
  • 2,119
  • 1
  • 13
  • 40
0
votes
1 answer

Unable To Strip Unused Bootstrap CSS Using Webpack Config

Using the configuration below, I'm able to create a single HTML file containing all my code correctly, but lots of unused bootstrap classes in there. Please note that I'm customising Bootstrap by importing SCSS files from node_modules into a…
Sammy
  • 3,395
  • 7
  • 49
  • 95
0
votes
1 answer

Nuxt deploy with AWS lambda serverless - Internal server error - CouldWatch: Cannot find module 'nuxt-purgecss'

I'm trying to deploy my nuxt app with serverless but get the error "Cannot find module 'nuxt-purgecss'". Any idea what could be the fix? Below my nuxt.config.js module.exports = { mode: "universal", /* ** Headers of the page */ head: { …
sbkl
  • 2,231
  • 2
  • 22
  • 28
0
votes
1 answer

Rails6 - PurgeCSS ignores styles from image_pack_tag

I'm following the TailwindCSS screencasts, railsifying them as I go. I have uncommented the image_pack lines in a/j/p/application.js: const images = require.context('../images', true) const imagePath = (name) => images(name, true) and can…
0
votes
1 answer

Run a gulp plugin that requires the current file path and name

I am using purgeCSS to removed unused CSS. My challenge is that I need to do this dynamically. Depending on the current .css file that is being processed, I need to get its path and file name so I can dynamically insert the content HTML path for…
expertCode
  • 533
  • 4
  • 14
0
votes
1 answer

Nuxt.js app deployed to Heroku only has TailwindCSS's styles for < SM breakpoint

I deployed my 1st Nuxt.js app to Heroku...Everything went smooth but when I opened the app I realised that every .vue file/component has TailwindCSS styles up untill SM breakpoint. Mobile view is fine, but anything bigger than SM breakpoint is not…
Boris Bosnjak
  • 21
  • 1
  • 6
0
votes
2 answers

Laravel Mix, TailwindCSS, and PurgeCSS

First time using laravel mix, I'm sure I'm missing something simple. I have a project where I'm attempting to use Laravel mix to compile tailwindcss and then use purge to remove any unused css. package.json "scripts": { "dev": "npm run…
CreateSean
  • 1,286
  • 1
  • 21
  • 42
0
votes
0 answers

TypeError: Cannot call a class as a function

I'm building out a new gulpfile and one of the tasks is to use purgecss However every time I run the task I get this error. TypeError: Cannot call a class as a function I cannot figure why this is happening and googling didn't help me. Javascript…
CreateSean
  • 1,286
  • 1
  • 21
  • 42
0
votes
1 answer

CSS-PURGE: Config is getting ignored

I try to use CSS-PURGE as system as a service to just notify a user if something could have been done better in his or her CSS. Thus I want CSS-PURGE to give me a report, which should work with the following configuration: { "options": { …
KittMedia
  • 7,368
  • 13
  • 34
  • 38
-1
votes
0 answers

what is the css syntax of classes sm, md, lg, xl of tailwind in the production file output.css

I began to use tailwind a few days ago, i succeeded to install, make it builting fine, but when my page was ended, nothing was working after running content (the purge of unnecessary css). So i correct the file output, adding forgotten classes by…
faure
  • 93
  • 8
-1
votes
1 answer

how to make css-purge to handle my css files in order I wrote

I want my exported file to have css lines to be in the order I wanted but it is not. How can I set css-purge to purge my css files in the order It should be and the order I put it in.
1 2 3 4 5
6