JeromeFitz
ae168edcfa
Remove babel-messages ( #6347 ), continuation of #6352
...
package.json "babel-messages" removed:
- babel-core
- babel-helper-replace-supers
- babel-plugin-transform-es2015-classes
- babel-traverse
"messages" remove from:
- babel-plugin-check-es2015-constants/src/index.js
- babel-plugin-transform-es2015-for-of/src/index.js
export "babel-messages" removed from:
- babel-core/src/index.js
import "babel-messages" removed from:
- babel-generator/src/index.js
- babel-helper-replace-supers/src/index.js
- babel-traverse/src/index.js
- babel-traverse/src/scope/index.js
- babel-traverse/src/visitors.js
package "babel-messages" removed completely.
💯 ️ All tests pass.
2017-09-30 09:31:53 -04:00
Henry Zhu
70547efcc1
v7.0.0-beta.2
2017-09-26 11:14:41 -04:00
Mateusz Burzyński
413ffe6639
Extracted babel-helper-annotate-as-pure ( #6267 )
2017-09-25 17:40:51 +02:00
Logan Smyth
b115ea5da7
Merge pull request #6280 from loganfsmyth/only-transform-modules
...
Only transform 'this'->'undefined' and inject 'use strict' if module statements are present
2017-09-23 11:24:52 -07:00
Logan Smyth
72da5e1d02
Quick fix for default import that also uses names. ( #6282 )
2017-09-21 22:26:42 -07:00
Mateusz Burzyński
9159323b1e
Skip adding explicit undefined for let declarations when it is not ne… ( #6288 )
2017-09-21 22:26:08 -07:00
Logan Smyth
2b88e079ef
Only transform this/use strict if a module.
2017-09-20 10:19:35 -07:00
Henry Zhu
23121d2bd3
v7.0.0-beta.1
2017-09-19 16:24:07 -04:00
Henry Zhu
57584268cd
move out syntax plugins to babel/babel-archive, they don't need to be updated ( #6229 )
2017-09-19 15:19:13 -04:00
Ajay Narain Mathur
3cdb7d7f0f
added instanceOf plugin to preset es2015 ( #6257 )
...
* added instanceOf plugin to preset es2015
* fixed test cases
2017-09-17 17:33:42 -04:00
Logan Smyth
158e9fbfd7
Represent helpers as simple modules.
2017-09-12 22:15:16 -07:00
Logan Smyth
1e750a945c
Convert CommonJS to use new shared implementation.
2017-09-12 17:17:41 -07:00
Henry Zhu
1c13250807
v7.0.0-beta.0
2017-09-11 23:01:41 -04:00
Justin Ridgewell
4daf11528c
Return inserted/replaced paths ( #5710 )
...
* Return inserted/replaced paths
This gives `Path`’s replacement and insertion methods a consistent
return value: the inserted/replaced paths.
Before, they could return `undefined`, a `node`, or a the current path
inside an array. It was kinda pointless. But now they always return an
array of paths, which is useful for solving
https://github.com/babel/babel/pull/4935#discussion_r96151368 .
* Return inserted nodes and not BlockStatement
Addded test for bug #4363
* Cleanups
- `#replaceWith` will now return the current path if it's the same node
- `#insertAfter` and `#insertBefore` use public Path APIs now
- Makes container insertion faster (single splice call)
- Use public APIs in container insertion
- Replacing a statement with an expression returns the expression's path
- Replacing an expression with multiple statements returns the inserted
closure's body's paths.
2017-09-11 16:07:04 -04:00
Mateusz Burzyński
c47258d68c
Annotating transformed classes with #__PURE__ comment ( #6209 )
2017-09-11 11:18:37 -04:00
Justin Ridgewell
f39811d271
Derived constructors don't always need a super ( #6189 )
2017-09-01 17:14:25 -04:00
Henry Zhu
b82b65a31e
v7.0.0-alpha.20
2017-08-30 15:02:49 -04:00
Justin Ridgewell
3e487f89ab
Don't merge test options. ( #6157 )
...
* Don't merge test options.
Particularly, I don't want `lodash/merge` to merge my specific plugins
with the general test plugins. It led to odd behavior where I could
enable a loose transform in my specific test, just to have it overridden
by the test fixture's general options.
* Need options
2017-08-28 13:36:03 -06:00
Oliver Don
960151c876
Fix #4840 : Alias class prototype for methods in loose mode ( #5560 )
...
* Fix #4840 : Alias class prototype for methods in loose mode
* Cleanup
2017-08-26 21:15:45 -04:00
Noah Lemen
2db0c3ad1d
linting: disallow t.identifier("undefined") in plugins ( #6096 )
...
* add new custom eslint rule, replace remaining t.identifier("undefined") with buildUndefinedNode(), update tests
* change no-undefined-identifier reporting descriptor
2017-08-24 15:43:01 -04:00
Mateusz Burzyński
fffa604023
Fixed regenerator related fixtures
2017-08-16 10:02:33 +02:00
Nicolò Ribaudo
b84f8e9234
Don't use _possibleConstructorReturn inside arrow functions ( #6103 )
...
Arrow functions can't be entrly skipped while traversing because this
references inside of them needs to be transformed, so I added a check
which prevents return statements inside arrow functions from being
saved for the transformation.
Fixes #5817 (regression)
2017-08-14 11:11:05 -04:00
Henry Zhu
79f4956948
v7.0.0-alpha.19
2017-08-07 18:21:08 -04:00
Henry Zhu
79c6814d65
v7.0.0-alpha.18
2017-08-03 18:20:36 -04:00
Henry Zhu
0f823beeb1
Newlines in fixtures ( #6044 )
...
* write newlines for fixtures
* rerun fixtures
2017-08-02 15:35:29 -04:00
Henry Zhu
9322fd0458
v7.0.0-alpha.17
2017-07-26 08:38:44 -04:00
Henry Zhu
7f1cd44d60
v7.0.0-alpha.16
2017-07-25 17:35:35 -04:00
Justin Ridgewell
28ae47a174
Stop mutating nodes ( #5963 )
...
* Stop mutating nodes
* Update tests
* linting
2017-07-18 13:24:07 -04:00
Justin Ridgewell
797fb3c2e4
Optimize and remove state from typeof-symbol transform ( #5955 )
...
Also fixes a bug with returning a Symbol from a Class constructor
(because the transform wasn’t run on helpers before).
2017-07-17 10:51:36 -04:00
Henry Zhu
a0f0411abf
v7.0.0-alpha.15
2017-07-11 23:35:22 -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
Justin Ridgewell
e170e6d760
Fix returning an object in a derived class constructor without super ( #5885 )
2017-07-11 17:43:19 -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
Henry Zhu
bb5528b414
Merge pull request #4850 from babel/removeClassCallCheck-option
...
Remove ClassCallCheck, possibleConstructorReturn in loose mode
2017-06-26 15:24:11 -04:00
Buu Nguyen
033bad3098
Fix bug super ref check doesn’t honor spec evaluation order ( #5801 )
2017-06-26 15:16:47 -04:00
Henry Zhu
4fdff567c6
remove superClass truthy check
2017-06-24 14:27:41 -04:00
Henry Zhu
8a4ab088e4
create and use a inheritsLoose helper
2017-06-19 11:58:49 -04:00
Henry Zhu
cdca54aed3
remove possibleConstructorReturn in loose mode as well
2017-06-09 18:42:52 -04:00
Henry Zhu
4081f3e23e
removeClassCallCheck option
2017-06-09 16:50:17 -04:00
Henry Zhu
123dce5fcd
Hardcode to double quotes, indent to 2 spaces ( #5824 )
2017-06-05 22:14:37 -05:00
Sven SAULEAU
bf9b434736
refactor: search parent instead of using state
2017-05-31 19:34:05 -05:00
Sven SAULEAU
819056e94a
fix: remove check for super in arrow function
2017-05-31 19:33:57 -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
Buu Nguyen
c474fd48e1
Fix issue semi-colon gets inserted unnecessarily ( #5749 )
...
* Fix issue semi-colon gets inserted unnecessarily
* Simplify if condition a bit
2017-05-19 16:54:51 -04: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