Skip to content

Commit

Permalink
Update babel-parser.d.ts (babel#13575)
Browse files Browse the repository at this point in the history
* Add moduleBlocks to ParserPlugin type

* Add TypeScriptPluginOptions to ParserPluginWithOptions
  • Loading branch information
sosukesuzuki authored and nicolo-ribaudo committed Jul 30, 2021
1 parent 815766c commit 4836ca5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/babel-parser/typings/babel-parser.d.ts
Expand Up @@ -131,6 +131,7 @@ export type ParserPlugin =
| "jsx"
| "logicalAssignment"
| "importAssertions"
| "moduleBlocks"
| "moduleStringNames"
| "nullishCoalescingOperator"
| "numericSeparator"
Expand All @@ -151,7 +152,8 @@ export type ParserPluginWithOptions =
| ["decorators", DecoratorsPluginOptions]
| ["pipelineOperator", PipelineOperatorPluginOptions]
| ["recordAndTuple", RecordAndTuplePluginOptions]
| ["flow", FlowPluginOptions];
| ["flow", FlowPluginOptions]
| ["typescript", TypeScriptPluginOptions];

export interface DecoratorsPluginOptions {
decoratorsBeforeExport?: boolean;
Expand All @@ -169,6 +171,10 @@ export interface FlowPluginOptions {
all?: boolean;
}

export interface TypeScriptPluginOptions {
dts?: boolean;
}

export const tokTypes: {
// todo(flow->ts) real token type
[name: string]: any;
Expand Down

0 comments on commit 4836ca5

Please sign in to comment.