Rename "babylon" to "@babel/parser" (#7937) 🎉
This commit is contained in:
committed by
Henry Zhu
parent
0200a3e510
commit
daf0ca8680
1
packages/babel-parser/test/fixtures/flow/declare-export/export-default-function/input.js
vendored
Normal file
1
packages/babel-parser/test/fixtures/flow/declare-export/export-default-function/input.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
declare export default function bar(p1: number): string;
|
||||
180
packages/babel-parser/test/fixtures/flow/declare-export/export-default-function/output.json
vendored
Normal file
180
packages/babel-parser/test/fixtures/flow/declare-export/export-default-function/output.json
vendored
Normal file
@@ -0,0 +1,180 @@
|
||||
{
|
||||
"type": "File",
|
||||
"start": 0,
|
||||
"end": 56,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 56
|
||||
}
|
||||
},
|
||||
"program": {
|
||||
"type": "Program",
|
||||
"start": 0,
|
||||
"end": 56,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 56
|
||||
}
|
||||
},
|
||||
"sourceType": "module",
|
||||
"body": [
|
||||
{
|
||||
"type": "DeclareExportDeclaration",
|
||||
"start": 0,
|
||||
"end": 56,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 56
|
||||
}
|
||||
},
|
||||
"declaration": {
|
||||
"type": "DeclareFunction",
|
||||
"start": 23,
|
||||
"end": 56,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 23
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 56
|
||||
}
|
||||
},
|
||||
"id": {
|
||||
"type": "Identifier",
|
||||
"start": 32,
|
||||
"end": 55,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 32
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 55
|
||||
},
|
||||
"identifierName": "bar"
|
||||
},
|
||||
"name": "bar",
|
||||
"typeAnnotation": {
|
||||
"type": "TypeAnnotation",
|
||||
"start": 35,
|
||||
"end": 55,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 35
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 55
|
||||
}
|
||||
},
|
||||
"typeAnnotation": {
|
||||
"type": "FunctionTypeAnnotation",
|
||||
"start": 35,
|
||||
"end": 55,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 35
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 55
|
||||
}
|
||||
},
|
||||
"typeParameters": null,
|
||||
"params": [
|
||||
{
|
||||
"type": "FunctionTypeParam",
|
||||
"start": 36,
|
||||
"end": 46,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 36
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 46
|
||||
}
|
||||
},
|
||||
"name": {
|
||||
"type": "Identifier",
|
||||
"start": 36,
|
||||
"end": 38,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 36
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 38
|
||||
},
|
||||
"identifierName": "p1"
|
||||
},
|
||||
"name": "p1"
|
||||
},
|
||||
"optional": false,
|
||||
"typeAnnotation": {
|
||||
"type": "NumberTypeAnnotation",
|
||||
"start": 40,
|
||||
"end": 46,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 40
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 46
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"rest": null,
|
||||
"returnType": {
|
||||
"type": "StringTypeAnnotation",
|
||||
"start": 49,
|
||||
"end": 55,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 49
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 55
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"predicate": null
|
||||
},
|
||||
"default": true
|
||||
}
|
||||
],
|
||||
"directives": []
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user