From 2f9cc653ba77b0eb58ebed40269bcb6923b3fe83 Mon Sep 17 00:00:00 2001 From: Ffloriel Date: Sun, 21 Mar 2021 21:43:30 +0000 Subject: [PATCH] feat: add dynamicAttributes option - add dynamicAttributes option to postcss plugin, rollup and webpack --- packages/postcss-purgecss/src/types/index.ts | 3 ++- packages/purgecss-webpack-plugin/src/types/index.ts | 1 + packages/rollup-plugin-purgecss/src/types/index.ts | 1 + 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/postcss-purgecss/src/types/index.ts b/packages/postcss-purgecss/src/types/index.ts index ad87ba7f..75169206 100644 --- a/packages/postcss-purgecss/src/types/index.ts +++ b/packages/postcss-purgecss/src/types/index.ts @@ -1,6 +1,6 @@ import { - UserDefinedSafelist, StringRegExpArray, + UserDefinedSafelist, } from "../../../purgecss/src/types/index"; export interface RawContent { @@ -31,4 +31,5 @@ export interface UserDefinedOptions { safelist?: UserDefinedSafelist; blocklist?: StringRegExpArray; skippedContentGlobs?: Array; + dynamicAttributes?: string[]; } diff --git a/packages/purgecss-webpack-plugin/src/types/index.ts b/packages/purgecss-webpack-plugin/src/types/index.ts index 17372a6b..e513e147 100644 --- a/packages/purgecss-webpack-plugin/src/types/index.ts +++ b/packages/purgecss-webpack-plugin/src/types/index.ts @@ -36,6 +36,7 @@ export interface UserDefinedOptions { safelist?: StringRegExpArray | ComplexSafelist | SafelistFunction; blocklist?: StringRegExpArray | BlocklistFunction; skippedContentGlobs?: Array; + dynamicAttributes?: string[]; only?: string[]; } diff --git a/packages/rollup-plugin-purgecss/src/types/index.ts b/packages/rollup-plugin-purgecss/src/types/index.ts index 1ba26c43..8c483fa6 100644 --- a/packages/rollup-plugin-purgecss/src/types/index.ts +++ b/packages/rollup-plugin-purgecss/src/types/index.ts @@ -33,6 +33,7 @@ export interface UserDefinedOptions { safelist?: UserDefinedSafelist; blocklist?: StringRegExpArray; skippedContentGlobs?: Array; + dynamicAttributes?: string[]; insert?: boolean; include?: string | RegExp | (string | RegExp)[];