Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@jsenv/node-esm-resolution

Package Overview
Dependencies
Maintainers
0
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@jsenv/node-esm-resolution - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

2

main.js

@@ -0,1 +1,3 @@

// tslint:disable:ordered-imports
export { applyNodeEsmResolution } from "./src/node_esm_resolution.js";

@@ -2,0 +4,0 @@ export { determineModuleSystem } from "./src/determine_module_system.js";

2

package.json
{
"name": "@jsenv/node-esm-resolution",
"version": "1.0.2",
"version": "1.0.3",
"license": "MIT",

@@ -5,0 +5,0 @@ "repository": {

import { existsSync } from "node:fs";
import { getParentUrl, asDirectoryUrl } from "./url_utils.js";
import { asDirectoryUrl, getParentUrl } from "./url_utils.js";

@@ -5,0 +5,0 @@ export const defaultLookupPackageScope = (url) => {

import { statSync } from "node:fs";
import { urlToFilename, urlToExtension } from "./url_utils.js";
import { urlToExtension, urlToFilename } from "./url_utils.js";

@@ -5,0 +5,0 @@ export const applyFileSystemMagicResolution = (

@@ -12,17 +12,17 @@ /*

*/
import { existsSync, readFileSync, realpathSync } from "node:fs";
import { pathToFileURL } from "node:url";
import { existsSync, readFileSync, realpathSync } from "node:fs";
import { isSpecifierForNodeBuiltin } from "./node_builtin_specifiers.js";
import { readCustomConditionsFromProcessArgs } from "./custom_conditions.js";
import { defaultLookupPackageScope } from "./default_lookup_package_scope.js";
import { defaultReadPackageJson } from "./default_read_package_json.js";
import { getParentUrl, isValidUrl } from "./url_utils.js";
import {
createInvalidModuleSpecifierError,
createInvalidPackageTargetError,
createModuleNotFoundError,
createPackageImportNotDefinedError,
createPackagePathNotExportedError,
createInvalidPackageTargetError,
} from "./errors.js";
import { readCustomConditionsFromProcessArgs } from "./custom_conditions.js";
import { isSpecifierForNodeBuiltin } from "./node_builtin_specifiers.js";
import { getParentUrl, isValidUrl } from "./url_utils.js";

@@ -107,6 +107,2 @@ export const applyNodeEsmResolution = ({

const packageResolution = applyPackageResolve(specifier, resolutionContext);
const search = new URL(specifier, "file://").search;
if (search) {
packageResolution.url = `${packageResolution.url}${search}`;
}
return packageResolution;

@@ -113,0 +109,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc