Socket
Socket
Sign inDemoInstall

typescript-transform-paths

Package Overview
Dependencies
Maintainers
2
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

typescript-transform-paths - npm Package Compare versions

Comparing version 3.4.4 to 3.4.5

7

CHANGELOG.md

@@ -5,2 +5,9 @@ # Changelog

### [3.4.5](https://github.com/LeDDGroup/typescript-transform-paths/compare/v3.4.4...v3.4.5) (2023-01-05)
### Bug Fixes
* OSX paths can be rewritten improperly (fixes [#167](https://github.com/LeDDGroup/typescript-transform-paths/issues/167)) ([0ff48d7](https://github.com/LeDDGroup/typescript-transform-paths/commit/0ff48d740edc58bed72971f6ad0f2c7493c56def))
### [3.4.4](https://github.com/LeDDGroup/typescript-transform-paths/compare/v3.4.3...v3.4.4) (2022-10-24)

@@ -7,0 +14,0 @@

4

dist/harmony/utils.d.ts

@@ -1,2 +0,2 @@

export declare type DownSampleTsTypes<TypeMap extends [any, any][], Tuple extends [...unknown[]]> = {
export type DownSampleTsTypes<TypeMap extends [any, any][], Tuple extends [...unknown[]]> = {
[i in keyof Tuple]: Tuple[i] extends any[] ? DownSampleTsTypes<TypeMap, Tuple[i]> : DownSampleTsType<TypeMap, Tuple[i]>;

@@ -6,3 +6,3 @@ } & {

};
declare type DownSampleTsType<TypeMap extends [any, any][], T> = T extends Exclude<TypeMap[number][0], undefined> ? Extract<TypeMap[number], [T, any]>[1] : T;
type DownSampleTsType<TypeMap extends [any, any][], T> = T extends Exclude<TypeMap[number][0], undefined> ? Extract<TypeMap[number], [T, any]>[1] : T;
export {};

@@ -5,4 +5,4 @@ import ts, { CompilerOptions, EmitHost, Pattern, SourceFile } from "typescript";

import { IMinimatch } from "minimatch";
export declare type ImportOrExportDeclaration = ts.ImportDeclaration | ts.ExportDeclaration;
export declare type ImportOrExportClause = ts.ImportDeclaration["importClause"] | ts.ExportDeclaration["exportClause"];
export type ImportOrExportDeclaration = ts.ImportDeclaration | ts.ExportDeclaration;
export type ImportOrExportClause = ts.ImportDeclaration["importClause"] | ts.ExportDeclaration["exportClause"];
export interface TsTransformPathsConfig extends PluginConfig {

@@ -9,0 +9,0 @@ readonly useRootDirs?: boolean;

@@ -5,1 +5,3 @@ export declare const isURL: (s: string) => boolean;

export declare const maybeAddRelativeLocalPrefix: (p: string) => string;
export declare function tryRealpathNative(value: string): string;
export declare function nativeRelativePath(from: string, to: string): string;

@@ -6,5 +6,6 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.maybeAddRelativeLocalPrefix = exports.isBaseDir = exports.cast = exports.isURL = void 0;
exports.nativeRelativePath = exports.tryRealpathNative = exports.maybeAddRelativeLocalPrefix = exports.isBaseDir = exports.cast = exports.isURL = void 0;
const url_1 = __importDefault(require("url"));
const path_1 = __importDefault(require("path"));
const fs_1 = require("fs");
/* ****************************************************************************************************************** *

@@ -24,2 +25,15 @@ * General Utilities & Helpers

exports.maybeAddRelativeLocalPrefix = maybeAddRelativeLocalPrefix;
function tryRealpathNative(value) {
try {
return fs_1.realpathSync.native(value);
}
catch (_a) {
return value;
}
}
exports.tryRealpathNative = tryRealpathNative;
function nativeRelativePath(from, to) {
return path_1.default.relative(tryRealpathNative(from), tryRealpathNative(to));
}
exports.nativeRelativePath = nativeRelativePath;
//# sourceMappingURL=general-utils.js.map

@@ -150,7 +150,7 @@ "use strict";

if (fileRootDir && moduleRootDir) {
srcFileOutputDir = path.relative(fileRootDir, srcFileOutputDir);
moduleFileOutputDir = path.relative(moduleRootDir, moduleFileOutputDir);
srcFileOutputDir = (0, general_utils_1.nativeRelativePath)(fileRootDir, srcFileOutputDir);
moduleFileOutputDir = (0, general_utils_1.nativeRelativePath)(moduleRootDir, moduleFileOutputDir);
}
}
const outputDir = path.relative(srcFileOutputDir, moduleFileOutputDir);
const outputDir = (0, general_utils_1.nativeRelativePath)(srcFileOutputDir, moduleFileOutputDir);
/* Compose final output path */

@@ -157,0 +157,0 @@ const outputPath = (0, general_utils_1.maybeAddRelativeLocalPrefix)(tsInstance.normalizePath(path.join(outputDir, outputBaseName)));

{
"name": "typescript-transform-paths",
"version": "3.4.4",
"version": "3.4.5",
"description": "Transforms module resolution paths using TypeScript path mapping and/or custom paths",

@@ -58,11 +58,11 @@ "main": "dist/index.js",

"@types/node": "^18.11.2",
"jest": "^29.2.1",
"jest": "^29.3.1",
"prettier": "^2.7.1",
"rimraf": "^3.0.2",
"standard-version": "^9.5.0",
"@types/ts-expose-internals": "npm:ts-expose-internals@4.8.4",
"@types/ts-expose-internals": "npm:ts-expose-internals@4.9.4",
"ts-jest": "^29.0.3",
"ts-node": "^10.9.1",
"ts-patch": "^1.4.5",
"typescript": "^4.8.4"
"ts-patch": "^2.1.0",
"typescript": "^4.9.4"
},

@@ -69,0 +69,0 @@ "peerDependencies": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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