@babel/plugin-transform-destructuring
Advanced tools
+3
-7
@@ -281,10 +281,6 @@ import { declare } from '@babel/helper-plugin-utils'; | ||
| if (!elem) continue; | ||
| let elemRef; | ||
| if (types.isRestElement(elem)) { | ||
| elemRef = this.toArray(arrayRef); | ||
| elemRef = types.callExpression(types.memberExpression(elemRef, types.identifier("slice")), [types.numericLiteral(i)]); | ||
| this.push(elem.argument, elemRef); | ||
| this.push(elem.argument, types.callExpression(types.memberExpression(types.callExpression(this.scope.path.hub.addHelper("arrayLikeToArray"), [arrayRef]), types.identifier("slice")), [types.numericLiteral(i)])); | ||
| } else { | ||
| elemRef = types.memberExpression(arrayRef, types.numericLiteral(i), true); | ||
| this.push(elem, elemRef); | ||
| this.push(elem, types.memberExpression(arrayRef, types.numericLiteral(i), true)); | ||
| } | ||
@@ -467,3 +463,3 @@ } | ||
| var index = declare((api, options) => { | ||
| api.assertVersion("8.0.0-beta.2"); | ||
| api.assertVersion("8.0.0-beta.3"); | ||
| const { | ||
@@ -470,0 +466,0 @@ useBuiltIns = false |
+6
-6
| { | ||
| "name": "@babel/plugin-transform-destructuring", | ||
| "version": "8.0.0-beta.2", | ||
| "version": "8.0.0-beta.3", | ||
| "description": "Compile ES2015 destructuring to ES5", | ||
@@ -20,11 +20,11 @@ "repository": { | ||
| "dependencies": { | ||
| "@babel/helper-plugin-utils": "^8.0.0-beta.2", | ||
| "@babel/traverse": "^8.0.0-beta.2" | ||
| "@babel/helper-plugin-utils": "^8.0.0-beta.3", | ||
| "@babel/traverse": "^8.0.0-beta.3" | ||
| }, | ||
| "peerDependencies": { | ||
| "@babel/core": "^8.0.0-beta.2" | ||
| "@babel/core": "^8.0.0-beta.3" | ||
| }, | ||
| "devDependencies": { | ||
| "@babel/core": "^8.0.0-beta.2", | ||
| "@babel/helper-plugin-test-runner": "^8.0.0-beta.2" | ||
| "@babel/core": "^8.0.0-beta.3", | ||
| "@babel/helper-plugin-test-runner": "^8.0.0-beta.3" | ||
| }, | ||
@@ -31,0 +31,0 @@ "engines": { |
Sorry, the diff of this file is not supported yet
84298
0.03%572
-0.69%