Skip to content

Commit

Permalink
fix: add safelist variables to postcss-purgecss #840
Browse files Browse the repository at this point in the history
  • Loading branch information
Ffloriel committed Feb 23, 2022
1 parent 8a54478 commit c822058
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/postcss-purgecss/src/index.ts
Expand Up @@ -32,6 +32,10 @@ async function purgeCSS(

purgeCSS.options = options;

if (options.variables) {
purgeCSS.variablesStructure.safelist = options.safelist.variables || [];
}

const { content, extractors } = options;

const fileFormatContents = content.filter(
Expand Down

0 comments on commit c822058

Please sign in to comment.