mirror of
https://github.com/status-im/metro.git
synced 2025-02-01 05:45:09 +00:00
Fix babel-generator Flow definition
Reviewed By: rafeca Differential Revision: D6692040 fbshipit-source-id: d15709b1d1f6a3d8e9befbf17e44623838eef033
This commit is contained in:
parent
2ab9c268b1
commit
0a9b45e01c
@ -102,7 +102,7 @@ type TransformResult = {
|
|||||||
type GeneratorResult = {
|
type GeneratorResult = {
|
||||||
code: string,
|
code: string,
|
||||||
map: ?_SourceMap,
|
map: ?_SourceMap,
|
||||||
rawMappings: ?Array<RawMapping>,
|
rawMappings: ?Array<_RawMapping>,
|
||||||
};
|
};
|
||||||
type VisitFn = <State>(path: Object, state: State) => any;
|
type VisitFn = <State>(path: Object, state: State) => any;
|
||||||
|
|
||||||
@ -131,7 +131,7 @@ declare module 'babel-core' {
|
|||||||
): TransformResult;
|
): TransformResult;
|
||||||
}
|
}
|
||||||
|
|
||||||
type RawMapping = {
|
type _RawMapping = {
|
||||||
generated: {column: number, line: number},
|
generated: {column: number, line: number},
|
||||||
name?: string,
|
name?: string,
|
||||||
original?: {column: number, line: number},
|
original?: {column: number, line: number},
|
||||||
@ -140,10 +140,10 @@ type RawMapping = {
|
|||||||
|
|
||||||
// https://github.com/babel/babel/tree/master/packages/babel-generator
|
// https://github.com/babel/babel/tree/master/packages/babel-generator
|
||||||
declare module 'babel-generator' {
|
declare module 'babel-generator' {
|
||||||
declare type RawMapping = RawMapping;
|
declare export type RawMapping = _RawMapping;
|
||||||
declare module.exports: {default: (
|
declare export default (
|
||||||
ast: Ast,
|
ast: Ast,
|
||||||
options?: GeneratorOptions,
|
options?: GeneratorOptions,
|
||||||
code?: string | {[string]: string},
|
code?: string | {[string]: string},
|
||||||
) => GeneratorResult};
|
) => GeneratorResult;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user