9088 Commits

Author SHA1 Message Date
Daniel Tschinder
d9dd32860a Fix replacing for-of if inside label (#4736)
This replaces the label instead of the for-of itself as we already
integrate the label in the replacement nodes.
Fixes #3858
2016-10-17 17:27:13 -04:00
Simen Bekkhus
9c2794dc85 Replace path-exists with fs.existsSync (#4731)
It's not deprecated anymore, see nodejs/node#8364
2016-10-17 14:31:49 -04:00
Moti Zilberman
05bdd4822a Merge pull request #4744 from nhajidin/fix-checkout
Fix line endings on checkout
2016-10-17 18:56:47 +03:00
Brian Ng
dfe896dd54 Avoid unnecessary +0 in transform-es2015-parameters (#4738) 2016-10-17 17:09:55 +02:00
Jordan Gensler
391e5bd813 [import()] Initial support for dynamic-import (#4699)
* [import()] Initial support for function-like import

* [import()] Renaming import-functions to dynamic-import

* [stage-2] Fixing lint error

* add to package.json
2016-10-17 11:02:00 -04:00
Nazim Hajidin
71e0e00bfe Fix line endings on checkout 2016-10-17 10:51:49 -04:00
Moti Zilberman
b8eeddf960 Automatically generate missing expected.js fixtures (#4735)
This is much like Babylon's existing behavior around `expected.json`. The equivalent of babel/babylon#188 is already applied here, to guard against silent failure (and a potential false positive) if a test is accidentally committed without its expected.js.
2016-10-17 16:39:32 +02:00
Brian Ng
478bba0ade Fix few typos in issue/pr templates (#4739) [skip ci] 2016-10-17 00:20:24 -04:00
Richard Macklin
6ec93d782b Extract resolveFromPossibleNames to remove duplicated logic
"DRY"s the duplicated algorithm in resolvePlugin and resolvePreset
2016-10-16 11:18:43 -07:00
Richard Macklin
4ea1007645 Remove unneeded tests
Previously these were testing the logic that is now encapsulated in
getPossiblePresetNames and tested in a unit test
2016-10-16 11:07:16 -07:00
Richard Macklin
e24f07dfda Extract resolvePreset method to babel-core public API
This encapsulates the logic for turning an acceptable preset name into
the absolute path for that preset. It can be used to preprocess a
presets list to map each preset to its absolute path, which is necessary
if `babel.transform` is going to be executed on a file outside the
directory subtree where the presets are installed.

This adds a getPossiblePresetNames helper encapsulating the logic for
what preset names we should try to resolve, and the resolvePreset method
just calls this helper and actually resolves them.
2016-10-16 11:06:47 -07:00
Richard Macklin
f4389a1886 Extract resolvePlugin method to babel-core public API
This encapsulates the logic for turning an acceptable plugin name into
the absolute path for that plugin. It can be used to preprocess a
plugins list to map each plugin to its absolute path, which is necessary
if `babel.transform` is going to be executed on a file outside the
directory subtree where the plugins are installed.

This adds a getPossiblePluginNames helper encapsulating the logic for
what plugin names we should try to resolve, and the resolvePlugin method
just calls this helper and actually resolves them.
2016-10-16 10:52:13 -07:00
Henry Zhu
2dc919d4c6 contributing updates [skip ci] 2016-10-15 19:27:24 -04:00
Henry Zhu
9299921d07 increase git depth [skip ci] 2016-10-15 18:52:14 -04:00
Andrew Levine
9f8ab29213 Change usage of "suite"/"test" in unit-tests to "describe"/"it" (#4734)
Fixes #4733
2016-10-15 18:45:35 -04:00
Andrew Levine
c0038221d7 Run ESLint on test files, and fix lint errors in test files (#4732) 2016-10-15 18:27:48 -04:00
Moti Zilberman
fd218abffb Add .gitattributes forcing LF line endings (#4730) 2016-10-15 10:29:12 -04:00
Henry Zhu
520d69b125 contributing a new plugin [skip ci] 2016-10-15 10:12:23 -04:00
Moti Zilberman
76de1cc8a4 Update tests for changed error messages in Babylon (#4727)
Depends on babel/babylon#172.
2016-10-14 16:25:56 -04:00
Moti Zilberman
2827d660fc Make special case for class property initializers in shadow-functions (#4502) 2016-10-14 15:21:11 -04:00
Brian Ng
fde16f10fa Add useBuiltIns option to helper-builder-react-jsx (#4655) 2016-10-14 21:18:39 +02:00
Sam Goldman
15183078e6 Add EmptyTypeAnnotation (#4724)
Added to Flow in facebook/flow#c603505583993aa953904005f91c350f4b65d6bd
Parser support added in babel/babylon#171.
2016-10-14 15:16:02 -04:00
Kai Cataldo
50baac3251 Remove babel-doctor from babel-cli (#4725)
* Remove babel-doctor from babel-cli

fixes #4678

* Throw when babel-doctor is used
2016-10-14 14:49:16 -04:00
Jamesernator
dc4140dc5f Fixed incorrect compilation of async iterator methods (#4719) 2016-10-14 14:38:57 -04: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
Henry Zhu
71790aace0 update eslint-config, fixes, add commands (#4721)
* update eslint-config, fixes, add commands

* switch plugin
2016-10-13 21:37:07 +02:00
Henry Zhu
5ab09c9617 0.0.6 2016-10-12 22:21:26 -04:00
Henry Zhu
d84ea7f478 ignore scripts 2016-10-12 22:21:23 -04:00
Henry Zhu
3604ff24c3 0.0.5 2016-10-12 22:18:02 -04:00
Henry Zhu
63d4aecf89 android/ios 2016-10-12 22:14:13 -04:00
Henry Zhu
a082a73869 add ie 2016-10-12 22:09:53 -04:00
Henry Zhu
3df730b490 cleanup 2016-10-12 22:08:22 -04:00
Henry Zhu
208e0ed4a4 error when no targets option is passed 2016-10-12 22:07:14 -04:00
Henry Zhu
15f05c0e9e back to upstream, update data for new ff 2016-10-12 21:46:43 -04:00
Henry Zhu
da318cd209 fix browserslist docs [skip ci] 2016-10-12 21:41:27 -04:00
Artem Yavorsky
03f6cae25f Adds browsers property to use browserslist's queries (#19)
* Use browserslist to parse browsers from query.

* Update README.

* Use int values.

* Allow `isPluginRequired` use browserslist queries.

* Fix conflicts during different versions merging.

* Add tests for browserslist queries.

* Early return for getTargets.

* Update README: Describe `browsers` option.

* fix doc [skip ci]

* Move to dependencies [skip ci]

* Remove unused const.

* Use doublequotes for strings.
2016-10-12 21:37:50 -04:00
Paul Sanchez
4a3893a49e Add Caveat section to Readme.md (#24) [skip ci]
* Add Caveat section to Readme.md

The Caveat section details some known issues and workaround when targeting specific environments and using specific plugins.

* fixes [skip ci]
2016-10-12 13:33:38 -04:00
Henry Zhu
09f135f9a1 fix spacing [skip ci] 2016-10-12 11:33:03 -04:00
Henry Zhu
668428097c add deprecated in readme for class-constructor-call [skip ci] 2016-10-12 10:17:19 -04:00
Henry Zhu
ccff8fa286 add deprecated in readme for class-constructor-call [skip ci] 2016-10-12 10:17:03 -04:00
Henry Zhu
9a979b5618 add deprecated description for class-constructor-call [skip ci] 2016-10-12 10:16:43 -04:00
Flavio Corpa
9b02a6d298 Add missing description to all package.json files (#4703) [skip ci] 2016-10-12 10:15:50 -04:00
Henry Zhu
9c7d8c4cad update phab links explanation [skip ci] 2016-10-12 08:45:52 -04:00
Daniel Tschinder
1dca51f8ab Enable babel for tests (#4564)
* Enable babel for tests

This enables babel for tests by using a mocha compiler
It uses the babel config from package.json
Transformed OptionsManager test to es2015 to see if it works
Removed the 5s timeout from cli tests, as the default timeout is already 10s, this should probably fix the timouts on travis that we had in babylon
Also run the cli tests on travis, they were disabled if istanbul active, but istanbul is always active on travis so we were never running this tests.

* ignore scripts directory

* only register for tests

* Set only flag correctly
2016-10-12 10:56:50 +02:00
Eric Rozell
c2387f0444 fix(shouldIgnore): filename normalization should be platform sensitive (#4631)
* fix(shouldIgnore): filename normalization should be platform sensitive

shouldIgnore normalizes the path of the filename prior to running any "only" regexes or functions. The normalization uses "slash", which has some undesirable special cases for non-ASCII characters and longer paths. Changing the normalization behavior to always replace path separators.

There is no real need to add additional tests, because the tests are not run in an environment where path.sep !== '/'.

* Minor style fix to use double quotes.

* Remove conditional for regex replace to keep consistent behavior.

* whitespace [skip ci]
2016-10-11 16:02:50 -04:00
Kai Cataldo
27ee74ea14 Better error messaging when preset options are given without a corresponding preset (#4685) 2016-10-11 16:56:53 +02:00
Henry Zhu
417a9c8dc3 mention process.versions.node [skip ci] 2016-10-11 09:10:11 -04:00
Henry Zhu
efbeb06c63 explain how it works [skip ci] 2016-10-08 11:20:03 -04:00
Daniel Tschinder
760bbd6014 🚀 Update home-or-tmp to version 2.0.0 (#4660) 2016-10-07 16:48:45 -04:00
Brian Ng
0aa3ac2bb5 Update babel parser options (#4688)
* Update babel parser options
2016-10-07 14:30:47 -04:00