Skip to content

Escaped Class Names Using Vars Incorrectly Set to undefined #137

@shellscape

Description

@shellscape

Consider the following CSS:

.bg-\\[url\\(https\\:\\/\\/example\\.com\\/image\\.png\\)\\] {
  --un-url: url(https://example.com/image.png); background-image:var(--un-url);
}

The output from running the plugin is:

.bg-\\[url\\(https\\:\\/\\/example\\.com\\/image\\.png\\)\\] {
  background-image:undefined;
}
.bg-\\[url\\(https\\:\\/\\/example\\.com\\/image\\.png\\)\\]:\\/\\/example\\.com\\/image\\.png\\)\\]{
  background-image:url(https://example.com/image.png);
}

The plugin seems to have an issue with escaping, or a variable directly following escaping.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions