@tbela99/css-parser
    Preparing search index...

    Interface TransformOptions

    transform options

    interface TransformOptions {
        beautify?: boolean;
        computeCalcExpression?: boolean;
        computeShorthand?: boolean;
        computeTransform?: boolean;
        convertColor?: boolean | ColorType;
        expandNestingRules?: boolean;
        features?: MinifyFeature[];
        indent?: string;
        inlineCssVariables?: boolean;
        lenient?: boolean;
        minify?: boolean;
        nestingRules?: boolean;
        newLine?: string;
        output?: string;
        parseColor?: boolean;
        pass?: number;
        preserveLicense?: boolean;
        removeCharset?: boolean;
        removeComments?: boolean;
        removeDuplicateDeclarations?: boolean;
        removeEmpty?: boolean;
        removePrefix?: boolean;
        resolveImport?: boolean;
        resolveUrls?: boolean;
        setParent?: boolean;
        signal?: AbortSignal;
        sourcemap?: boolean | "inline";
        src?: string;
        validation?: boolean | ValidationLevel;
        visitor?: VisitorNodeMap;
        withParents?: boolean;
    }

    Hierarchy (View Summary)

    Index

    Properties

    beautify?: boolean

    pretty print css

    computeCalcExpression?: boolean

    compute math functions see supported functions mathFuncs

    computeShorthand?: boolean

    compute shorthand properties

    computeTransform?: boolean

    compute transform functions see supported functions transformFunctions

    convertColor?: boolean | ColorType

    convert color to the specified color space. 'true' will convert to HEX

    expandNestingRules?: boolean

    expand nested rules

    features?: MinifyFeature[]

    minify features

    indent?: string

    indent string

    inlineCssVariables?: boolean

    inline css variables

    lenient?: boolean

    lenient validation. retain nodes that failed validation

    minify?: boolean

    enable minification

    nestingRules?: boolean

    generate nested rules

    newLine?: string

    new line string

    output?: string

    output file. used for url resolution

    parseColor?: boolean

    parse color tokens

    pass?: number

    define minification passes.

    preserveLicense?: boolean

    preserve license comments. license comments are comments that start with /*!

    removeCharset?: boolean

    remove

    at-rule

    removeComments?: boolean

    remove comments

    removeDuplicateDeclarations?: boolean

    remove duplicate declarations from the same rule

    removeEmpty?: boolean

    remove empty ast nodes

    removePrefix?: boolean

    remove css prefix

    resolveImport?: boolean

    resolve import

    resolveUrls?: boolean

    resolve urls

    setParent?: boolean

    set parent node

    signal?: AbortSignal

    abort signal

    Example: abort after 10 seconds


    const result = await parse(cssString, {
    signal: AbortSignal.timeout(10000)
    });
    sourcemap?: boolean | "inline"

    include sourcemap in the ast. sourcemap info is always generated

    src?: string

    source file to be used for sourcemap

    validation?: boolean | ValidationLevel

    enable css validation

    see ValidationLevel

    visitor?: VisitorNodeMap

    node visitor VisitorNodeMap

    withParents?: boolean

    ernder the node along with its parents