Skip to content

Commit 8d66a58

Browse files
authored
Merge pull request #155 from benasher44/patch-1
Recommend import = in MissingExportEquals.md
2 parents 5499c36 + 89ab548 commit 8d66a58

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docs/problems/MissingExportEquals.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@ This merging namespace can also be used to declare the `default` property when t
5353
```ts
5454
declare function Whatever(props: Whatever.WhateverProps): void;
5555
declare namespace Whatever {
56-
declare const _default: typeof Whatever;
56+
// using `import =` syntax ensures the CJS-default-import continues to work as a namespace
57+
import _default = Whatever;
5758
export { _default as default };
5859

5960
export interface WhateverProps {

0 commit comments

Comments
 (0)