Gathering detailed insights and metrics for purgecss-webpack-plugin
Gathering detailed insights and metrics for purgecss-webpack-plugin
Gathering detailed insights and metrics for purgecss-webpack-plugin
Gathering detailed insights and metrics for purgecss-webpack-plugin
@fullhuman/postcss-purgecss
PostCSS plugin for PurgeCSS
purgecss
Remove unused css selectors
gatsby-plugin-purgecss
Gatsby plugin for purgecss. Removes unused css/sass/less/stylus from files and modules. Supports Tailwindcss, Bootstrap, Bulma etc.
purgecss-whitelister
A utility for creating whitelists of CSS selectors for use with Purgecss.
npm install purgecss-webpack-plugin
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
7,802 Stars
1,502 Commits
248 Forks
55 Watching
8 Branches
76 Contributors
Updated on 25 Nov 2024
TypeScript (81.35%)
CSS (12.04%)
JavaScript (4.45%)
HTML (2.16%)
Cumulative downloads
Total Downloads
Last day
12.7%
13,155
Compared to previous day
Last week
2.8%
62,887
Compared to previous week
Last month
15.5%
263,885
Compared to previous month
Last year
-14.5%
3,082,359
Compared to previous year
1
3
When you are building a website, chances are that you are using a css framework like Bootstrap, Materializecss, Foundation, etc... But you will only use a small set of the framework and a lot of unused css styles will be included.
This is where PurgeCSS comes into play. PurgeCSS analyzes your content and your css files. Then it matches the selectors used in your css files with the ones in your content files. It removes unused selectors from your css, resulting in smaller css files.
You can find the PurgeCSS documentation on this website.
1npm install purgecss --save-dev
1import { PurgeCSS } from "purgecss"; 2const purgeCSSResults = await new PurgeCSS().purge({ 3 content: ["**/*.html"], 4 css: ["**/*.css"], 5});
This repository is a monorepo that we manage using Lerna. That means that we actually publish several packages to npm from the same codebase, including:
Package | Version | Description |
---|---|---|
purgecss | The core of PurgeCSS | |
postcss-purgecss | PostCSS plugin for PurgeCSS | |
purgecss-webpack-plugin | Webpack plugin for PurgeCSS | |
gulp-purgecss | Gulp plugin for PurgeCSS | |
grunt-purgecss | Grunt plugin for PurgeCSS | |
rollup-plugin-purgecss | Rollup plugin for PurgeCSS | |
purgecss-from-html | Html extractor for PurgeCSS | |
purgecss-from-pug | Pug extractor for PurgeCSS | |
purgecss-with-wordpress | Collection of safelist items for WordPress | |
vue-cli-plugin-purgecss | Vue CLI Plugin for PurgeCSS |
No vulnerabilities found.
Reason
30 commit(s) and 6 issue activity found in the last 90 days -- score normalized to 10
Reason
no dangerous workflow patterns detected
Reason
security policy file detected
Details
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
SAST tool is run on all commits
Details
Reason
1 existing vulnerabilities detected
Details
Reason
Found 0/13 approved changesets -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
project is not fuzzed
Details
Score
Last Scanned on 2024-11-25
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More