@jsenv/node-esm-resolution 1.0.3 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jsenv/node-esm-resolution",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -103,6 +103,12 @@ const applyPackageSpecifierResolution = (specifier, resolutionContext) => {
103
103
  return browserFieldResolution;
104
104
  }
105
105
  const packageResolution = applyPackageResolve(specifier, resolutionContext);
106
+ if (packageResolution.type !== "relative_specifier") {
107
+ const search = new URL(specifier, "file://").search;
108
+ if (search) {
109
+ packageResolution.url = `${packageResolution.url}${search}`;
110
+ }
111
+ }
106
112
  return packageResolution;
107
113
  }
108
114
  };