Mauro Bringolf
b83e0ec7b0
2nd try: Add loose option for es2015-parameters transformation ( #5943 )
...
* Import changes to parameters package from previous branch
* Refactor plugin option access via state
2017-07-12 17:36:44 -04:00
Henry Zhu
a0f0411abf
v7.0.0-alpha.15
2017-07-11 23:35:22 -04:00
Buu Nguyen
8decefe8bc
Fix bug incorrect dereferencing rest argument ( #5810 )
...
* Fix bug incorrect dereferencing rest argument
* Fix pure path
* Minor refactor
2017-07-11 23:26:57 -04:00
Henry Zhu
03f249430a
v7.0.0-alpha.14
2017-07-11 22:53:09 -04:00
Henry Zhu
8460b4c62f
v7.0.0-alpha.13
2017-07-11 22:27:56 -04:00
Daniel Tschinder
b3372a572d
Remove whitespace generation ( #5833 )
...
* Remove whitespace generation and rely on default printing
Changes to printing:
* Add newline after last empty SwitchCase
* Add newlines around block comments if they are non-flow comments or contain newlines
* Fix a few more fixtures
2017-06-27 21:57:02 -05:00
Brian Ng
e4b35f680d
Run prettier
2017-06-27 12:15:00 -05:00
Justin Ridgewell
5387d9f903
Merge pull request #5721 from Qantas94Heavy/rest-parameters-5656
...
Fix optimisation of shadowed rest parameters
2017-06-13 13:57:53 -04:00
Henry Zhu
123dce5fcd
Hardcode to double quotes, indent to 2 spaces ( #5824 )
2017-06-05 22:14:37 -05:00
Henry Zhu
c5bad22767
v7.0.0-alpha.12
2017-05-31 17:11:39 -04:00
Henry Zhu
ce976bba2a
v7.0.0-alpha.11
2017-05-31 16:43:30 -04:00
Henry Zhu
9b44cef691
v7.0.0-alpha.10
2017-05-25 15:17:07 -04:00
Karl Cheng
0667160b11
Fix optimisation of shadowed rest parameters
...
The arguments of a function would be unnecessarily copied if there was
a nested function that had a parameter with the same identifier as the
rest parameter for the outer function. This checks the scope of the
parameter is correct before deoptimising.
Fixes: https://github.com/babel/babel/issues/5656
Refs: https://github.com/babel/babel/issues/2091
2017-05-16 22:39:13 +10:00
Logan Smyth
14584c218c
Kill the "shadow-functions.js" internal plugin in favor of an explicit helper ( #5677 )
...
* Handle arrow function processing via shared API rather than default plugin.
* Fix a few small PR comments.
* Preserve existing spec arrow 'this' rewrites, and support spec in subclass constructors.
2017-05-05 13:27:18 -07:00
Henry Zhu
62375cdf12
v7.0.0-alpha.9
2017-04-18 10:41:30 -04:00
Henry Zhu
25ae8c8554
v7.0.0-alpha.8
2017-04-17 15:12:31 -04:00
Henry Zhu
c732f5e1d0
v7.0.0-alpha.7
2017-04-05 17:13:26 -04:00
Henry Zhu
f3ef03abfd
use caret for devDeps
2017-03-27 16:32:13 -04:00
Henry Zhu
7a1ccf076c
Misc ( #5545 )
...
* normalize npmignores
* fixup eslint ignore, etc
* lint
* remove unused
* rm from gitignore
* use strict
2017-03-25 21:46:16 -04:00
Henry Zhu
ab68800e06
v7.0.0-alpha.3
2017-03-23 15:49:01 -04:00
Nitin Tulswani
8c1cd177b2
added examples for transforms. [skip ci] ( #5393 )
2017-03-14 09:43:51 -05:00
Henry Zhu
230712e091
Internal: back to fixed, publish everything ( #5436 )
2017-03-08 22:56:00 -05:00
Brian Ng
8a82cc060a
Run new lint rules ( #5413 )
2017-03-04 10:46:01 -05:00
Henry Zhu
11e54a6bd3
v7.0.0-alpha.1
2017-03-02 16:04:47 -05:00
Daniel Tschinder
6c03cb0783
Merge branch 'master' into merge-master
...
# Conflicts:
# lerna.json
# packages/babel-cli/package.json
# packages/babel-core/package.json
# packages/babel-generator/package.json
# packages/babel-helper-builder-react-jsx/package.json
# packages/babel-helper-function-name/package.json
# packages/babel-helper-optimise-call-expression/package.json
# packages/babel-helper-replace-supers/package.json
# packages/babel-helper-transform-fixture-test-runner/package.json
# packages/babel-helpers/package.json
# packages/babel-plugin-transform-class-properties/package.json
# packages/babel-plugin-transform-es2015-block-scoping/package.json
# packages/babel-plugin-transform-es2015-classes/package.json
# packages/babel-plugin-transform-es2015-modules-commonjs/package.json
# packages/babel-plugin-transform-es2015-modules-systemjs/package.json
# packages/babel-plugin-transform-es2015-modules-umd/package.json
# packages/babel-plugin-transform-es2015-parameters/package.json
# packages/babel-plugin-transform-react-jsx/package.json
# packages/babel-register/package.json
# packages/babel-template/package.json
# packages/babel-traverse/package.json
# packages/babel/package.json
2017-02-14 12:46:23 +01:00
Logan Smyth
48573f1fb4
v6.23.0
2017-02-13 17:14:12 -08:00
Henry Zhu
9083bd6283
Merge branch 'master' into 7.0
2017-02-09 18:36:02 -05:00
Logan Smyth
b845f2b69d
Re-enable the max-len ESLint rule. ( #5265 )
2017-02-04 11:07:15 -05:00
Kai Cataldo
e09ea222c9
Remove babel-runtime from packages' dependencies ( #5218 )
2017-01-27 09:04:35 -05:00
Henry Zhu
e9fc38bcd3
v6.22.0
2017-01-19 19:33:22 -05:00
Brian Ng
8c35b320d3
Bump eslint-config-babel and fix lint ( #5129 )
2017-01-17 10:51:16 +01:00
Sergey Rubanov
292c3ca206
Refactor test packages to use ES modules instead of CJS ( #5138 )
2017-01-16 11:25:04 -05:00
Henry Zhu
672adba9a1
enable prefer const ( #5113 )
2017-01-14 09:48:52 -05:00
Sven SAULEAU
982850731e
fix: [skip ci] consistent documentation ( #5111 )
2017-01-14 09:45:20 -05:00
Henry Zhu
77d9e3e5c4
v6.21.0
2016-12-16 16:55:53 -05:00
Henry Zhu
bfe4faa0d9
fix tests
2016-12-16 11:50:57 -05:00
Justin Ridgewell
852348d700
Fix default parameter - rest parameter edge case ( #3572 )
...
When the rest parameter shared the same name as a default identifier
for a param, the loop would be hoisted outside the function!
```js
var a = 1;
for (var _len = arguments.length, a = Array(_len > 1 ? _len - 1 : 0),
_key = 1; _key < _len; _key++) {
a[_key - 1] = arguments[_key];
}
function foo2() {
var b = arguments.length <= 0 || arguments[0] === undefined ? a :
arguments[0];
assert.equal(b, 1);
}
foo2(undefined, 2);
```
And if you tried to reference any index or `#length`, it’d blow up and
refuse to transpile.
2016-12-16 10:53:52 -05:00
Tommaso
27e201e0e1
Update plugins READMEs from babel.github.io [skip ci] ( #4931 )
2016-12-02 17:07:16 -06:00
Brian Ng
f71efbce92
Update transform-es2015 READMEs from babel.github.io [skip ci] ( #4926 )
...
Signed-off-by: Brian Ng <bng412@gmail.com>
2016-12-01 16:11:36 -05:00
Henry Zhu
e86f62b304
README: add --save-dev [skip ci]
...
Closes gh-4910
2016-11-29 08:40:27 -05:00
Sven SAULEAU
2311b5b53a
README: remove dollar in sh snippets [skip ci]
2016-11-29 08:39:23 -05:00
Henry Zhu
12f9cd0826
v6.18.0
2016-10-24 17:18:36 -04:00
Brian Ng
dfe896dd54
Avoid unnecessary +0 in transform-es2015-parameters ( #4738 )
2016-10-17 17:09:55 +02:00
Moti Zilberman
9fc51d6292
Consolidate contiguous var declarations in destructuring transform ( #4690 )
...
* Consolidate contiguous var declarations in destructuring transform
Fixes #3081 .
* Simplify var node coalescing in es2015-destructuring
* Revert "Simplify var node coalescing in es2015-destructuring"
This reverts commit 15cb373f0726f68225f7080a7ae206a63af174ee.
* More careful condition for var coalescing in es2015-destructuring
2016-10-14 11:51:22 -04:00
Dan Harper
33eb56ab09
fix error when constructor default arg refers to own static property or self ( #4666 )
...
(closes #4253 )
(closes #4442 )
2016-10-05 17:52:42 -04:00
Moti Zilberman
0366d1ad19
Handle side effects correctly in rest params index expressions ( #4348 ) ( #4674 )
2016-10-05 21:59:41 +02:00
Moti Zilberman
12d2673038
Add test for rest params name collision with top-level name ( #4333 ) ( #4673 )
2016-10-05 10:15:04 -04:00
Henry Zhu
e50b3c890f
v6.17.0
2016-10-01 15:23:18 -04:00
Daniel Tschinder
16716ea3de
Fix rest parameters with flow type casting ( #4636 )
...
Do not skip TypeCastExpressions when finding referenced identifiers as the
type cast contains valid non flow code that we need to visit.
2016-10-01 12:58:14 -04:00
Henry Zhu
6d22f258db
v6.16.0
2016-09-28 15:38:45 -04:00