Skip to content

Commit d316d1a

Browse files
committed
fix: rewrite type imports. also preserve comments
1 parent 95eea30 commit d316d1a

File tree

21 files changed

+135
-13
lines changed

21 files changed

+135
-13
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// eslint-disable-next-line node/no-missing-import
12
import print from "../../print/dist/index.mjs";
23
print("TypeScript");
34
//# sourceMappingURL=index.mjs.map

integration/__file_snapshots__/project-references/multiple-targets/main/dist/index.mjs.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

integration/__file_snapshots__/project-references/only-esnext/main/dist/index.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

integration/__file_snapshots__/project-references/only-esnext/main/dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

integration/__file_snapshots__/single-project/multiple-targets/dist/index.mjs.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

integration/__file_snapshots__/single-project/only-esnext/dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
dist/index.cjs
2+
dist/index.d.cts
3+
dist/index.d.mts
4+
dist/index.mjs
5+
dist/print.cjs
6+
dist/print.d.cts
7+
dist/print.d.mts
8+
dist/print.mjs
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
"use strict";
2+
Object.defineProperty(exports, "__esModule", { value: true });
3+
exports.inferred = exports.x = void 0;
4+
const print_1 = require("./print.cjs");
5+
exports.x = "Type";
6+
exports.inferred = (0, print_1.print)(exports.x);
7+
// const inferred: import("./print").PrintResult;
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
export declare const x: import("./print.cjs").Printable;
2+
export declare const inferred: import("./print.cjs").PrintResult;
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
export declare const x: import("./print.mjs").Printable;
2+
export declare const inferred: import("./print.mjs").PrintResult;

0 commit comments

Comments
 (0)