-
Notifications
You must be signed in to change notification settings - Fork 12.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
96bffce
commit 09330b8
Showing
44 changed files
with
2,289 additions
and
0 deletions.
There are no files selected for viewing
23 changes: 23 additions & 0 deletions
23
tests/baselines/reference/esmNoSynthesizedDefault(module=esnext).errors.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/index.ts(1,8): error TS1192: Module '"/node_modules/mdast-util-to-string/index"' has no default export. | ||
/index.ts(7,8): error TS2339: Property 'default' does not exist on type 'typeof import("/node_modules/mdast-util-to-string/index")'. | ||
|
||
|
||
==== /node_modules/mdast-util-to-string/package.json (0 errors) ==== | ||
{ "type": "module" } | ||
|
||
==== /node_modules/mdast-util-to-string/index.d.ts (0 errors) ==== | ||
export function toString(): string; | ||
|
||
==== /index.ts (2 errors) ==== | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
~~~~~ | ||
!!! error TS1192: Module '"/node_modules/mdast-util-to-string/index"' has no default export. | ||
mdast; | ||
mdast.toString(); | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
mdast2.toString(); | ||
mdast2.default; | ||
~~~~~~~ | ||
!!! error TS2339: Property 'default' does not exist on type 'typeof import("/node_modules/mdast-util-to-string/index")'. | ||
|
25 changes: 25 additions & 0 deletions
25
tests/baselines/reference/esmNoSynthesizedDefault(module=esnext).js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
//// [tests/cases/compiler/esmNoSynthesizedDefault.ts] //// | ||
|
||
//// [package.json] | ||
{ "type": "module" } | ||
|
||
//// [index.d.ts] | ||
export function toString(): string; | ||
|
||
//// [index.ts] | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
mdast; | ||
mdast.toString(); | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
mdast2.toString(); | ||
mdast2.default; | ||
|
||
|
||
//// [index.js] | ||
import mdast from 'mdast-util-to-string'; | ||
mdast; | ||
mdast.toString(); | ||
const mdast2 = await import('mdast-util-to-string'); | ||
mdast2.toString(); | ||
mdast2.default; |
29 changes: 29 additions & 0 deletions
29
tests/baselines/reference/esmNoSynthesizedDefault(module=esnext).symbols
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
//// [tests/cases/compiler/esmNoSynthesizedDefault.ts] //// | ||
|
||
=== /node_modules/mdast-util-to-string/index.d.ts === | ||
export function toString(): string; | ||
>toString : Symbol(toString, Decl(index.d.ts, 0, 0)) | ||
|
||
=== /index.ts === | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
>mdast : Symbol(mdast, Decl(index.ts, 0, 6)) | ||
>toString : Symbol(toString, Decl(index.ts, 0, 15)) | ||
|
||
mdast; | ||
>mdast : Symbol(mdast, Decl(index.ts, 0, 6)) | ||
|
||
mdast.toString(); | ||
>mdast : Symbol(mdast, Decl(index.ts, 0, 6)) | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
>mdast2 : Symbol(mdast2, Decl(index.ts, 4, 5)) | ||
>'mdast-util-to-string' : Symbol("/node_modules/mdast-util-to-string/index", Decl(index.d.ts, 0, 0)) | ||
|
||
mdast2.toString(); | ||
>mdast2.toString : Symbol(toString, Decl(index.d.ts, 0, 0)) | ||
>mdast2 : Symbol(mdast2, Decl(index.ts, 4, 5)) | ||
>toString : Symbol(toString, Decl(index.d.ts, 0, 0)) | ||
|
||
mdast2.default; | ||
>mdast2 : Symbol(mdast2, Decl(index.ts, 4, 5)) | ||
|
37 changes: 37 additions & 0 deletions
37
tests/baselines/reference/esmNoSynthesizedDefault(module=esnext).types
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
//// [tests/cases/compiler/esmNoSynthesizedDefault.ts] //// | ||
|
||
=== /node_modules/mdast-util-to-string/index.d.ts === | ||
export function toString(): string; | ||
>toString : () => string | ||
|
||
=== /index.ts === | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
>mdast : any | ||
>toString : () => string | ||
|
||
mdast; | ||
>mdast : any | ||
|
||
mdast.toString(); | ||
>mdast.toString() : any | ||
>mdast.toString : any | ||
>mdast : any | ||
>toString : any | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
>mdast2 : typeof import("/node_modules/mdast-util-to-string/index") | ||
>await import('mdast-util-to-string') : typeof import("/node_modules/mdast-util-to-string/index") | ||
>import('mdast-util-to-string') : Promise<typeof import("/node_modules/mdast-util-to-string/index")> | ||
>'mdast-util-to-string' : "mdast-util-to-string" | ||
|
||
mdast2.toString(); | ||
>mdast2.toString() : string | ||
>mdast2.toString : () => string | ||
>mdast2 : typeof import("/node_modules/mdast-util-to-string/index") | ||
>toString : () => string | ||
|
||
mdast2.default; | ||
>mdast2.default : any | ||
>mdast2 : typeof import("/node_modules/mdast-util-to-string/index") | ||
>default : any | ||
|
23 changes: 23 additions & 0 deletions
23
tests/baselines/reference/esmNoSynthesizedDefault(module=preserve).errors.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/index.ts(1,8): error TS1192: Module '"/node_modules/mdast-util-to-string/index"' has no default export. | ||
/index.ts(7,8): error TS2339: Property 'default' does not exist on type 'typeof import("/node_modules/mdast-util-to-string/index")'. | ||
|
||
|
||
==== /node_modules/mdast-util-to-string/package.json (0 errors) ==== | ||
{ "type": "module" } | ||
|
||
==== /node_modules/mdast-util-to-string/index.d.ts (0 errors) ==== | ||
export function toString(): string; | ||
|
||
==== /index.ts (2 errors) ==== | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
~~~~~ | ||
!!! error TS1192: Module '"/node_modules/mdast-util-to-string/index"' has no default export. | ||
mdast; | ||
mdast.toString(); | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
mdast2.toString(); | ||
mdast2.default; | ||
~~~~~~~ | ||
!!! error TS2339: Property 'default' does not exist on type 'typeof import("/node_modules/mdast-util-to-string/index")'. | ||
|
25 changes: 25 additions & 0 deletions
25
tests/baselines/reference/esmNoSynthesizedDefault(module=preserve).js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
//// [tests/cases/compiler/esmNoSynthesizedDefault.ts] //// | ||
|
||
//// [package.json] | ||
{ "type": "module" } | ||
|
||
//// [index.d.ts] | ||
export function toString(): string; | ||
|
||
//// [index.ts] | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
mdast; | ||
mdast.toString(); | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
mdast2.toString(); | ||
mdast2.default; | ||
|
||
|
||
//// [index.js] | ||
import mdast from 'mdast-util-to-string'; | ||
mdast; | ||
mdast.toString(); | ||
const mdast2 = await import('mdast-util-to-string'); | ||
mdast2.toString(); | ||
mdast2.default; |
29 changes: 29 additions & 0 deletions
29
tests/baselines/reference/esmNoSynthesizedDefault(module=preserve).symbols
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
//// [tests/cases/compiler/esmNoSynthesizedDefault.ts] //// | ||
|
||
=== /node_modules/mdast-util-to-string/index.d.ts === | ||
export function toString(): string; | ||
>toString : Symbol(toString, Decl(index.d.ts, 0, 0)) | ||
|
||
=== /index.ts === | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
>mdast : Symbol(mdast, Decl(index.ts, 0, 6)) | ||
>toString : Symbol(toString, Decl(index.ts, 0, 15)) | ||
|
||
mdast; | ||
>mdast : Symbol(mdast, Decl(index.ts, 0, 6)) | ||
|
||
mdast.toString(); | ||
>mdast : Symbol(mdast, Decl(index.ts, 0, 6)) | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
>mdast2 : Symbol(mdast2, Decl(index.ts, 4, 5)) | ||
>'mdast-util-to-string' : Symbol("/node_modules/mdast-util-to-string/index", Decl(index.d.ts, 0, 0)) | ||
|
||
mdast2.toString(); | ||
>mdast2.toString : Symbol(toString, Decl(index.d.ts, 0, 0)) | ||
>mdast2 : Symbol(mdast2, Decl(index.ts, 4, 5)) | ||
>toString : Symbol(toString, Decl(index.d.ts, 0, 0)) | ||
|
||
mdast2.default; | ||
>mdast2 : Symbol(mdast2, Decl(index.ts, 4, 5)) | ||
|
37 changes: 37 additions & 0 deletions
37
tests/baselines/reference/esmNoSynthesizedDefault(module=preserve).types
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
//// [tests/cases/compiler/esmNoSynthesizedDefault.ts] //// | ||
|
||
=== /node_modules/mdast-util-to-string/index.d.ts === | ||
export function toString(): string; | ||
>toString : () => string | ||
|
||
=== /index.ts === | ||
import mdast, { toString } from 'mdast-util-to-string'; | ||
>mdast : any | ||
>toString : () => string | ||
|
||
mdast; | ||
>mdast : any | ||
|
||
mdast.toString(); | ||
>mdast.toString() : any | ||
>mdast.toString : any | ||
>mdast : any | ||
>toString : any | ||
|
||
const mdast2 = await import('mdast-util-to-string'); | ||
>mdast2 : typeof import("/node_modules/mdast-util-to-string/index") | ||
>await import('mdast-util-to-string') : typeof import("/node_modules/mdast-util-to-string/index") | ||
>import('mdast-util-to-string') : Promise<typeof import("/node_modules/mdast-util-to-string/index")> | ||
>'mdast-util-to-string' : "mdast-util-to-string" | ||
|
||
mdast2.toString(); | ||
>mdast2.toString() : string | ||
>mdast2.toString : () => string | ||
>mdast2 : typeof import("/node_modules/mdast-util-to-string/index") | ||
>toString : () => string | ||
|
||
mdast2.default; | ||
>mdast2.default : any | ||
>mdast2 : typeof import("/node_modules/mdast-util-to-string/index") | ||
>default : any | ||
|
37 changes: 37 additions & 0 deletions
37
tests/baselines/reference/impliedNodeFormatEmit1(module=amd).errors.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
error TS5095: Option 'bundler' can only be used when 'module' is set to 'preserve' or to 'es2015' or later. | ||
|
||
|
||
!!! error TS5095: Option 'bundler' can only be used when 'module' is set to 'preserve' or to 'es2015' or later. | ||
==== /a.ts (0 errors) ==== | ||
export const _ = 0; | ||
|
||
==== /b.mts (0 errors) ==== | ||
export const _ = 0; | ||
|
||
==== /c.cts (0 errors) ==== | ||
export const _ = 0; | ||
|
||
==== /d.js (0 errors) ==== | ||
export const _ = 0; | ||
|
||
==== /e.mjs (0 errors) ==== | ||
export const _ = 0; | ||
|
||
==== /f.mjs (0 errors) ==== | ||
export const _ = 0; | ||
|
||
==== /g.ts (0 errors) ==== | ||
import {} from "./a"; | ||
import a = require("./a"); | ||
|
||
==== /h.mts (0 errors) ==== | ||
import {} from "./a"; | ||
import a = require("./a"); | ||
|
||
==== /i.cts (0 errors) ==== | ||
import {} from "./a"; | ||
import a = require("./a"); | ||
|
||
==== /dummy.ts (0 errors) ==== | ||
export {}; | ||
|
98 changes: 98 additions & 0 deletions
98
tests/baselines/reference/impliedNodeFormatEmit1(module=amd).js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
//// [tests/cases/compiler/impliedNodeFormatEmit1.ts] //// | ||
|
||
//// [a.ts] | ||
export const _ = 0; | ||
|
||
//// [b.mts] | ||
export const _ = 0; | ||
|
||
//// [c.cts] | ||
export const _ = 0; | ||
|
||
//// [d.js] | ||
export const _ = 0; | ||
|
||
//// [e.mjs] | ||
export const _ = 0; | ||
|
||
//// [f.mjs] | ||
export const _ = 0; | ||
|
||
//// [g.ts] | ||
import {} from "./a"; | ||
import a = require("./a"); | ||
|
||
//// [h.mts] | ||
import {} from "./a"; | ||
import a = require("./a"); | ||
|
||
//// [i.cts] | ||
import {} from "./a"; | ||
import a = require("./a"); | ||
|
||
//// [dummy.ts] | ||
export {}; | ||
|
||
|
||
//// [a.js] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports._ = void 0; | ||
exports._ = 0; | ||
}); | ||
//// [b.mjs] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports._ = void 0; | ||
exports._ = 0; | ||
}); | ||
//// [c.cjs] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports._ = void 0; | ||
exports._ = 0; | ||
}); | ||
//// [d.js] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports._ = void 0; | ||
exports._ = 0; | ||
}); | ||
//// [e.mjs] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports._ = void 0; | ||
exports._ = 0; | ||
}); | ||
//// [f.mjs] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports._ = void 0; | ||
exports._ = 0; | ||
}); | ||
//// [g.js] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
}); | ||
//// [h.mjs] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
}); | ||
//// [i.cjs] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
}); | ||
//// [dummy.js] | ||
define(["require", "exports"], function (require, exports) { | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
}); |
Oops, something went wrong.