OptionalanalyzeOptionalcssWhether to compile this file as a CSS module.
OptionalcustomDefines how to parse custom CSS at-rules. Each at-rule can have a prelude, defined using a CSS syntax string, and a block body. The body can be a declaration list, rule list, or style block as defined in the css spec.
OptionaldraftsWhether to enable parsing various draft syntax.
OptionalerrorWhether to ignore invalid rules and declarations rather than erroring. When enabled, warnings are returned, and the invalid rule or declaration is omitted from the output code.
OptionalexcludeFeatures that should never be compiled, even when unsupported by targets.
OptionalincludeFeatures that should always be compiled, even when supported by targets.
OptionalinputAn input source map to extend.
OptionalminifyWhether to enable minification
OptionalnonWhether to enable various non-standard syntax.
OptionalprojectAn optional project root path, used as the source root in the output source map. Also used to generate relative paths for sources used in CSS module hashes.
OptionalpseudoReplaces user action pseudo classes with class names that can be applied from JavaScript. This is useful for polyfills, for example.
OptionalsourceWhether to output a source map.
OptionaltargetsThe browser targets for the generated code.
OptionalunusedWhether to remove unused selectors or keywords.
OptionalvisitorAn AST visitor object. This allows custom transforms or analysis to be implemented in JavaScript.
Multiple visitors can be composed into one using the composeVisitors function.
For optimal performance, visitors should be as specific as possible about what types of values
they care about so that JavaScript has to be called as little as possible.
Whether to analyze dependencies (e.g.
@importandurl()). When enabled,@importrules are removed, andurl()dependencies are replaced with hashed placeholders that can be replaced with the final urls later (after bundling). Dependencies are returned as part of the result.