mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-30 01:04:49 -05:00
Ensure moduleType is structured during cloneTypeAsModuleType (#51136)
This commit is contained in:
36
tests/cases/compiler/moduleExportNonStructured.ts
Normal file
36
tests/cases/compiler/moduleExportNonStructured.ts
Normal file
@@ -0,0 +1,36 @@
|
||||
// @target: ESNext
|
||||
// @module: ESNext
|
||||
// @moduleResolution: NodeNext
|
||||
// @strict: true
|
||||
|
||||
// @filename: package.json
|
||||
{
|
||||
"name": "test",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"type": "module",
|
||||
"module": "index.mjs"
|
||||
}
|
||||
|
||||
// @filename: index.mts
|
||||
import * as exportAny from "./exportAny.cjs";
|
||||
import * as exportUnknown from "./exportUnknown.cjs";
|
||||
import * as exportSymbol from "./exportSymbol.cjs";
|
||||
|
||||
import type * as exportAnyType from "./exportAny.cjs";
|
||||
import type * as exportUnknownType from "./exportUnknown.cjs";
|
||||
import type * as exportSymbolType from "./exportSymbol.cjs";
|
||||
|
||||
// @filename: exportAny.d.cts
|
||||
declare const __: any;
|
||||
export = __;
|
||||
|
||||
|
||||
// @filename: exportUnknown.d.cts
|
||||
declare const __: unknown;
|
||||
export = __;
|
||||
|
||||
|
||||
// @filename: exportSymbol.d.cts
|
||||
declare const __: symbol;
|
||||
export = __;
|
||||
Reference in New Issue
Block a user