Skip to content

Replace isCSSRequest check with moduleNode.type === 'css' #617

@hi-ogawa

Description

@hi-ogawa

All occurrence of isCSSRequest except getRscCssTransformFilter heuristics can be replaced with type === 'css' check

// skip transform if no css imports
const result = esModuleLexer.parse(code)
if (!result[0].some((i) => i.t === 1 && i.n && isCSSRequest(i.n))) {
return false
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions