Skip to content

Mappings only work for default entry points of JSR packages? #475

@gadicc

Description

@gadicc

Input:

import * as path from "@std/path";
import { globToRegExp } from "@std/path/glob-to-regexp";

Output:

import * as path from "../../deps/jsr.io/@std/path/1.1.2/mod.js";
import { globToRegExp } from "@std/path/glob-to-regexp"; // <-- problem

and without the first line, deps/jsr.io/@std/path won't exist either.

Easy workaround in this case is to simply:

-import { globToRegExp } from "@std/path/glob-to-regexp";
+import { globToRegExp } from "@std/path";

But of course that depends on the default entry point exporting what you need.

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