tsconfig-paths
Advanced tools
Comparing version 2.2.0 to 2.3.0
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var TsConfigLoader = require("./tsconfig-loader"); | ||
@@ -3,0 +4,0 @@ var path = require("path"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
// register is used from register.js in root dir | ||
@@ -3,0 +4,0 @@ var match_path_1 = require("./match-path"); |
@@ -10,2 +10,3 @@ "use strict"; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var package_reader_1 = require("./package-reader"); | ||
@@ -87,2 +88,5 @@ var fs = require("fs"); | ||
function tryResolve(physicalPath, fileExists, readPackageJson, extensions) { | ||
if (path.extname(path.basename(physicalPath)).length > 0 && fileExists(physicalPath)) { | ||
return physicalPath; | ||
} | ||
if (extensions.reduce(function (prev, curr) { return prev || fileExists(physicalPath + curr); }, false)) { | ||
@@ -89,0 +93,0 @@ return physicalPath; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
/** | ||
@@ -3,0 +4,0 @@ * Matches pattern with a single star against search. |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var fs = require("fs"); | ||
@@ -3,0 +4,0 @@ /** |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_path_1 = require("./match-path"); | ||
@@ -19,12 +20,12 @@ var config_loader_1 = require("./config-loader"); | ||
var Module = require('module'); | ||
var originalLoader = Module._load; | ||
Module._load = function (request, parent) { | ||
var originalResolveFilename = Module._resolveFilename; | ||
Module._resolveFilename = function (request, parent) { | ||
var found = matchPath(parent, request); | ||
if (found) { | ||
var modifiedArguments = [found].concat([].slice.call(arguments, 1)); | ||
return originalLoader.apply(this, modifiedArguments); | ||
var modifiedArguments = [found].concat([].slice.call(arguments, 1)); // Passes all arguments. Even those that is not specified above. | ||
return originalResolveFilename.apply(this, modifiedArguments); | ||
} | ||
return originalLoader.apply(this, arguments); | ||
return originalResolveFilename.apply(this, arguments); | ||
}; | ||
} | ||
exports.register = register; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var Tsconfig = require("tsconfig"); | ||
@@ -3,0 +4,0 @@ function tsConfigLoader(_a) { |
{ | ||
"name": "tsconfig-paths", | ||
"version": "2.2.0", | ||
"version": "2.3.0", | ||
"description": "Load node modules according to tsconfig paths, in run-time or via API.", | ||
@@ -18,4 +18,4 @@ "main": "lib/index.js", | ||
"shelljs": "^0.7.5", | ||
"ts-node": "^2.0.0", | ||
"typescript": "^2.1.4" | ||
"ts-node": "^3.1.0", | ||
"typescript": "^2.4.1" | ||
}, | ||
@@ -22,0 +22,0 @@ "scripts": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
246920
1094
0