Skip to content

Accept File URLs in a VLQ Map #116

@binyamin

Description

@binyamin

Summary

When a VLQ Map's contains a File URL in the map's sources array, this module should preserve the "file://" URL scheme. Currently, it will strip the scheme and the leading slash, making it impossible for browsers to resolve correctly.

Relevance: By default, dart-sass generates file URLs. Which makes sense, because it's referring to files on the disk, not hosted files. This module mutilates the URL. Which means it will generate two sources for one file.

Before

{
    version: 3,
    sources: [
        "file:///home/binyamin/fake/style.scss"
    ],
    // ... rest of source-map
}

After

{
    version: 3,
    sources: [
        "home/binyamin/fake/style.scss"
    ],
    // ... rest of source-map
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions