Skip to content
This repository was archived by the owner on Jan 14, 2019. It is now read-only.

feat: align TSModuleDeclaration with babel-typescript #38

Merged
merged 1 commit into from
Nov 30, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/convert.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2527,6 +2527,9 @@ export default function convert(config: ConvertConfig): ESTreeNode | null {
}
// apply modifiers first...
applyModifiersToResult((node as any).modifiers);
if (node.flags & ts.NodeFlags.GlobalAugmentation) {
result.global = true;
}
// ...then check for exports
result = nodeUtils.fixExports(node, result as any, ast);
break;
Expand Down
1 change: 1 addition & 0 deletions src/temp-types-based-on-js-source.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ export interface ESTreeNode {
decorators?: any;
const?: boolean;
declare?: boolean;
global?: boolean;
modifiers?: any;
body?: any;
params?: any;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
declare global {
declare module global {

}
declare namespace global {

}
}
Loading