Skip to content

pantoken-root / plugins/postcss/props-minify/src / pruneCustomProps

Zmienna: pruneCustomProps ​

const pruneCustomProps: {(): Plugin; postcss: true; }

Beta

Utwórz wtyczkę PostCSS prune-unused-custom-properties.

Type Declaration ​

Zwraca ​

Plugin

PostCSS wtyczka.

postcss ​

postcss: true

Wymagany znacznik wtyczki PostCSS.

Przykład ​

Uruchom ją jako samodzielny przebieg PostCSS

ts
import postcss from "postcss";
import { pruneCustomProps } from "@pantoken/plugin-prune-custom-props";

const out = postcss([pruneCustomProps()]).process(css, { from: undefined }).css;
// only the --instui-* custom properties reachable from real declarations survive