Update babel to v7.20.0 (#13733)
This commit is contained in:
1 parent
4f13d715c7
commit
40f3bced17
5 files changed
+30
-31
No files matched your search
+3
-3
@@ -31,8 +31,8 @@
|
||||
"dependencies": {
|
||||
"@angular/compiler": "14.2.7",
|
||||
"@babel/code-frame": "7.18.6",
|
||||
"@babel/parser": "7.19.6",
|
||||
"@babel/types": "7.19.4",
|
||||
"@babel/parser": "7.20.0",
|
||||
"@babel/types": "7.20.0",
|
||||
"@glimmer/syntax": "0.84.2",
|
||||
"@iarna/toml": "2.2.5",
|
||||
"@prettier/is-es5-identifier-name": "0.0.2",
|
||||
@@ -104,7 +104,7 @@
|
||||
"yaml-unist-parser": "2.0.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/generator": "7.19.6",
|
||||
"@babel/generator": "7.20.0",
|
||||
"@esbuild-plugins/node-modules-polyfill": "0.1.4",
|
||||
"@glimmer/reference": "0.84.2",
|
||||
"@types/estree": "1.0.0",
|
||||
|
||||
+6
-10
@@ -4,20 +4,16 @@ import isNonEmptyArray from "../utils/is-non-empty-array.js";
|
||||
* @typedef {import("./types/estree.js").Node} Node
|
||||
*/
|
||||
|
||||
function locStart(node, opts) {
|
||||
const { ignoreDecorators } = opts || {};
|
||||
function locStart(node) {
|
||||
const start = node.range ? node.range[0] : node.start;
|
||||
|
||||
// Handle nodes with decorators. They should start at the first decorator
|
||||
if (!ignoreDecorators) {
|
||||
const decorators =
|
||||
(node.declaration && node.declaration.decorators) || node.decorators;
|
||||
|
||||
if (isNonEmptyArray(decorators)) {
|
||||
return locStart(decorators[0]);
|
||||
}
|
||||
const decorators = node.declaration?.decorators ?? node.decorators;
|
||||
if (isNonEmptyArray(decorators)) {
|
||||
return Math.min(locStart(decorators[0]), start);
|
||||
}
|
||||
|
||||
return node.range ? node.range[0] : node.start;
|
||||
return start;
|
||||
}
|
||||
|
||||
function locEnd(node) {
|
||||
|
||||
@@ -74,8 +74,7 @@ function hasDecoratorsBeforeExport(node) {
|
||||
const decorators = node.declaration && node.declaration.decorators;
|
||||
|
||||
return (
|
||||
isNonEmptyArray(decorators) &&
|
||||
locStart(node, { ignoreDecorators: true }) > locStart(decorators[0])
|
||||
isNonEmptyArray(decorators) && locStart(node) === locStart(decorators[0])
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -868,6 +868,10 @@ exports[`visitor keys estree 1`] = `
|
||||
"TSRestType": [
|
||||
"typeAnnotation",
|
||||
],
|
||||
"TSSatisfiesExpression": [
|
||||
"expression",
|
||||
"typeAnnotation",
|
||||
],
|
||||
"TSStaticKeyword": [],
|
||||
"TSStringKeyword": [],
|
||||
"TSSymbolKeyword": [],
|
||||
|
||||
@@ -84,14 +84,14 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@babel/generator@npm:7.19.6, @babel/generator@npm:^7.18.10, @babel/generator@npm:^7.7.2":
|
||||
version: 7.19.6
|
||||
resolution: "@babel/generator@npm:7.19.6"
|
||||
"@babel/generator@npm:7.20.0, @babel/generator@npm:^7.18.10, @babel/generator@npm:^7.7.2":
|
||||
version: 7.20.0
|
||||
resolution: "@babel/generator@npm:7.20.0"
|
||||
dependencies:
|
||||
"@babel/types": ^7.19.4
|
||||
"@babel/types": ^7.20.0
|
||||
"@jridgewell/gen-mapping": ^0.3.2
|
||||
jsesc: ^2.5.1
|
||||
checksum: 734fcb1fbef182e7b8967459cb39b81edd2701dd13170c154b368d4e086842f72ef214798c5a37e67e0a695dfb34b13143277bedcd9795b3b1b83da8e1d236c6
|
||||
checksum: df2fef0ac305cf031013e311d4582b15b5c297fd538bec71e6cae3b689189ac4be6055482487b06da1be2f007b8985d5162a84e14e43a20435b8c89551910509
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -228,12 +228,12 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@babel/parser@npm:7.19.6, @babel/parser@npm:^7.1.0, @babel/parser@npm:^7.14.7, @babel/parser@npm:^7.18.10, @babel/parser@npm:^7.18.11":
|
||||
version: 7.19.6
|
||||
resolution: "@babel/parser@npm:7.19.6"
|
||||
"@babel/parser@npm:7.20.0, @babel/parser@npm:^7.1.0, @babel/parser@npm:^7.14.7, @babel/parser@npm:^7.18.10, @babel/parser@npm:^7.18.11":
|
||||
version: 7.20.0
|
||||
resolution: "@babel/parser@npm:7.20.0"
|
||||
bin:
|
||||
parser: ./bin/babel-parser.js
|
||||
checksum: 9a3dca4ee3acd7e4fc3b58e1e1526a11fa334acbfe437f8ebf91dfaf48e943c147ef64b1733ba0a55af57d1eccafbf4e4a4afc46a15becd921971fe2ddf309bf
|
||||
checksum: d54d68e45ff1b9a0c50a3f79d9031f482eb58f18928525949dc20da5b1658ee79167e756129371fd75d3e8fc7e218ab707727145a68958636be9672c7b71768e
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -420,14 +420,14 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@babel/types@npm:7.19.4, @babel/types@npm:^7.0.0, @babel/types@npm:^7.18.10, @babel/types@npm:^7.18.6, @babel/types@npm:^7.18.9, @babel/types@npm:^7.19.4, @babel/types@npm:^7.3.0, @babel/types@npm:^7.3.3, @babel/types@npm:^7.8.3":
|
||||
version: 7.19.4
|
||||
resolution: "@babel/types@npm:7.19.4"
|
||||
"@babel/types@npm:7.20.0, @babel/types@npm:^7.0.0, @babel/types@npm:^7.18.10, @babel/types@npm:^7.18.6, @babel/types@npm:^7.18.9, @babel/types@npm:^7.20.0, @babel/types@npm:^7.3.0, @babel/types@npm:^7.3.3, @babel/types@npm:^7.8.3":
|
||||
version: 7.20.0
|
||||
resolution: "@babel/types@npm:7.20.0"
|
||||
dependencies:
|
||||
"@babel/helper-string-parser": ^7.19.4
|
||||
"@babel/helper-validator-identifier": ^7.19.1
|
||||
to-fast-properties: ^2.0.0
|
||||
checksum: 4032f6407093f80dd4f4764be676f7527d2a5c0381586967cd79683cf8af01cdc16745a381b9cef045f702f0c9b0dffd880d84ee55dad59ba01bd23d5d52a8e0
|
||||
checksum: 8729b1114c707a03625cd79e3ae3a28d69b36ddcf804cb0a4599af226e5e9fad71665bdc0e56c43527ecfcabc545d9c797231f5ce718ae1ab52d31a57b6c2024
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -6611,9 +6611,9 @@ __metadata:
|
||||
dependencies:
|
||||
"@angular/compiler": 14.2.7
|
||||
"@babel/code-frame": 7.18.6
|
||||
"@babel/generator": 7.19.6
|
||||
"@babel/parser": 7.19.6
|
||||
"@babel/types": 7.19.4
|
||||
"@babel/generator": 7.20.0
|
||||
"@babel/parser": 7.20.0
|
||||
"@babel/types": 7.20.0
|
||||
"@esbuild-plugins/node-modules-polyfill": 0.1.4
|
||||
"@glimmer/reference": 0.84.2
|
||||
"@glimmer/syntax": 0.84.2
|
||||
|
||||
Reference in new issue
Block a user