-
Notifications
You must be signed in to change notification settings - Fork 202
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: support
export *
statements (#1962)
- Loading branch information
1 parent
183b426
commit 1b27258
Showing
8 changed files
with
199 additions
and
73 deletions.
There are no files selected for viewing
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
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 |
---|---|---|
@@ -1,8 +1,5 @@ | ||
import ts from "typescript"; | ||
import type ts from "typescript"; | ||
|
||
export function symbolAtNode(node: ts.Node): ts.Symbol | undefined { | ||
return (node as any).symbol; | ||
} | ||
export function localSymbolAtNode(node: ts.Node): ts.Symbol | undefined { | ||
return (node as any).localSymbol; | ||
return (node as ts.Declaration).symbol; | ||
} |
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
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
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,5 @@ | ||
export type A = 1; | ||
|
||
export type B = "string"; | ||
|
||
type C = "internal"; |
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,6 @@ | ||
export * from "./literal"; | ||
export * from "./object"; | ||
|
||
export type External = 1; | ||
|
||
type Internal = 2; |
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,11 @@ | ||
export interface D { | ||
a: 1; | ||
} | ||
|
||
export class E { | ||
b: 2; | ||
} | ||
|
||
interface F { | ||
internal: true; | ||
} |
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,43 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"definitions": { | ||
"A": { | ||
"const": 1, | ||
"type": "number" | ||
}, | ||
"B": { | ||
"const": "string", | ||
"type": "string" | ||
}, | ||
"D": { | ||
"additionalProperties": false, | ||
"properties": { | ||
"a": { | ||
"const": 1, | ||
"type": "number" | ||
} | ||
}, | ||
"required": [ | ||
"a" | ||
], | ||
"type": "object" | ||
}, | ||
"E": { | ||
"additionalProperties": false, | ||
"properties": { | ||
"b": { | ||
"const": 2, | ||
"type": "number" | ||
} | ||
}, | ||
"required": [ | ||
"b" | ||
], | ||
"type": "object" | ||
}, | ||
"External": { | ||
"const": 1, | ||
"type": "number" | ||
} | ||
} | ||
} |