awesome-repositories.com
Blog
awesome-repositories.com

Découvrez les meilleurs dépôts open-source grâce à notre recherche par IA.

ExplorerRecherches sélectionnéesAlternatives open sourceLogiciels auto-hébergésBlogPlan du site
ProjetÀ proposNotre méthodologiePresseServeur MCP
Mentions légalesConfidentialitéConditions d'utilisation
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
FullHuman avatar

FullHuman/purgecss

0
View on GitHub↗
8,043 stars·244 forks·TypeScript·MIT·2 vuespurgecss.com↗

Purgecss

PurgeCSS est un outil de nettoyage et d'optimisation CSS pour pipelines de build, conçu pour réduire la taille finale des feuilles de style. Il fonctionne comme un outil de « tree shaking » qui analyse les fichiers HTML et JavaScript pour identifier et supprimer les sélecteurs CSS inutilisés.

L'outil optimise les payloads CSS en effectuant une analyse statique du contenu pour détecter quels styles sont réellement utilisés dans le balisage. Il utilise des expressions régulières pour trouver des noms de classes potentiels sans exécuter de code et emploie une transformation AST basée sur PostCSS pour supprimer en toute sécurité les règles inutilisées.

Le projet offre des capacités d'automatisation du build frontend, permettant d'intégrer la suppression des styles inutilisés directement dans les bundlers de modules et les task runners. Il inclut également un filtre de liste blanche personnalisée pour préserver les sélecteurs essentiels, indépendamment de leur détection lors de l'analyse du contenu.

Features

  • CSS Selector Purging - Removes CSS rules whose selectors do not match any elements found during the static content scan.
  • Content Pattern Matching - Uses regex-based pattern matching to identify potential CSS class names within HTML and JavaScript files.
  • CSS AST Transformations - Employs a PostCSS-based AST transformation to safely remove unused rules from the stylesheet structure.
  • Markup Usage Analysis - Scans HTML and JavaScript files to create a comprehensive list of all CSS selectors used in the markup.
  • CSS Payload Reduction - Reduces the total byte size of delivered CSS by purging redundant and unused rules.
  • CSS Unused Style Removers - Automates the removal of unused styles by integrating with module bundlers and task runners.
  • CSS Build Tools - Acts as a build-time engine that scans source files to optimize and compile CSS styles.
  • Frontend Build Toolchains - Integrates style cleanup directly into the frontend build toolchain for automated deployment.
  • Build Tool Integrations - Integrates directly as an extension within common build systems to automate stylesheet optimization.
  • CSS Selector Whitelists - Provides a whitelist filter to ensure essential CSS selectors are preserved regardless of content analysis.
  • Web Performance Tuning - Eliminates dead CSS code to decrease browser rendering time and minimize data transfer.
  • CSS Optimization - Remove unused CSS to reduce file size.

Historique des stars

Graphique de l'historique des stars pour fullhuman/purgecssGraphique de l'historique des stars pour fullhuman/purgecss

Recherche par IA

Explorez plus de dépôts awesome

Décrivez vos besoins en langage naturel — l'IA classe des milliers de projets open source sélectionnés par pertinence.

Start searching with AI

Alternatives open source à Purgecss

Projets open source similaires, classés selon le nombre de fonctionnalités partagées avec Purgecss.
  • uncss/uncssAvatar de uncss

    uncss/uncss

    9,408Voir sur GitHub↗

    Uncss is a build pipeline CSS optimizer and optimization tool designed to remove unused styles from stylesheets. It analyzes HTML files to identify and strip selectors that do not match any elements in the markup, reducing the final stylesheet size and overall web page weight. The tool functions as a DOM-based CSS analyzer that can simulate runtime document states. It provides mechanisms to preserve required selectors through the use of literal names, regular expressions, and specialized CSS comment markers to ensure styles triggered by user interactions are not deleted. The project supports

    JavaScriptbuild-toolcleanupcss
    Voir sur GitHub↗9,408
  • purifycss/purifycssAvatar de purifycss

    purifycss/purifycss

    9,863Voir sur GitHub↗

    PurifyCSS is a CSS unused style remover and payload optimizer that analyzes HTML and templates to identify and delete unused CSS selectors from stylesheets. It functions as a frontend build automation tool that integrates into development pipelines to automatically strip redundant styles and minify assets during the compilation phase. The tool provides specific optimization for single page applications, identifying and removing redundant CSS while ensuring necessary styles are preserved across dynamic views and states. The utility covers a range of capabilities including static content analy

    JavaScript
    Voir sur GitHub↗9,863
  • uncss/grunt-uncssAvatar de uncss

    uncss/grunt-uncss

    3,795Voir sur GitHub↗

    grunt-uncss is a CSS dead code eliminator and static analysis build tool. It functions as a Grunt CSS optimization plugin that identifies and deletes redundant style rules to reduce stylesheet file sizes and improve frontend performance. The tool analyzes HTML files and headless browser DOM states to detect styles that do not match any elements in the markup. It supports the protection of specific selectors through whitelists to ensure that styles for dynamically injected elements are preserved during the cleanup process. The project covers frontend asset minification by compressing cleaned

    HTML
    Voir sur GitHub↗3,795
  • windicss/windicssAvatar de windicss

    windicss/windicss

    6,515Voir sur GitHub↗

    Windi CSS is a utility-first CSS framework that generates only the CSS classes actually used in a project, scanning source files at build time to produce smaller, optimized stylesheets. It provides on-demand style generation through static analysis of HTML and template files, eliminating unused styles for leaner output. The framework offers a plugin-based extension system for adding custom utilities, variants, and design tokens without modifying the core. It includes built-in compatibility for migrating from Tailwind CSS, removing Tailwind-specific dependencies and configuration fields while

    TypeScriptcsscss-compileron-demand
    Voir sur GitHub↗6,515
Voir les 30 alternatives à Purgecss→

Questions fréquentes

Que fait fullhuman/purgecss ?

PurgeCSS est un outil de nettoyage et d'optimisation CSS pour pipelines de build, conçu pour réduire la taille finale des feuilles de style. Il fonctionne comme un outil de « tree shaking » qui analyse les fichiers HTML et JavaScript pour identifier et supprimer les sélecteurs CSS inutilisés.

Quelles sont les fonctionnalités principales de fullhuman/purgecss ?

Les fonctionnalités principales de fullhuman/purgecss sont : CSS Selector Purging, Content Pattern Matching, CSS AST Transformations, Markup Usage Analysis, CSS Payload Reduction, CSS Unused Style Removers, CSS Build Tools, Frontend Build Toolchains.

Quelles sont les alternatives open-source à fullhuman/purgecss ?

Les alternatives open-source à fullhuman/purgecss incluent : uncss/uncss — Uncss is a build pipeline CSS optimizer and optimization tool designed to remove unused styles from stylesheets. It… purifycss/purifycss — PurifyCSS is a CSS unused style remover and payload optimizer that analyzes HTML and templates to identify and delete… uncss/grunt-uncss — grunt-uncss is a CSS dead code eliminator and static analysis build tool. It functions as a Grunt CSS optimization… windicss/windicss — Windi CSS is a utility-first CSS framework that generates only the CSS classes actually used in a project, scanning… cssnano/cssnano — cssnano is a CSS compression tool and minifier that reduces the file size and gzip footprint of stylesheets. It… facebook/stylex — StyleX is a type-safe CSS-in-JS library and atomic CSS compiler that transforms JavaScript style definitions into…