Closed
Description
Bug Report
We can no longer use export =
in a d.ts file when 'verbatimModuleSyntax' is enabled ?
Should the 'verbatimModuleSyntax' check the d.ts file?
The d.ts file has no any side effects.
TS Version: 5.0.1-rc
💻 Code
// type1.d.ts
declare namespace NS {
type A = object;
}
export = NS;
export as namespace MyTypes;
// type2.d.ts
import type * as NS from 'moduleA';
export = NS;
export as namespace ModuleATypes;
🙁 Actual behavior
TS1282: An 'export =' declaration must reference a value when 'verbatimModuleSyntax' is enabled, but 'NS' only refers to a type.
🙂 Expected behavior
compile success