101 Commits

Author SHA1 Message Date
Brian Ng
1092dde11c Add tests for debug output (#156) 2017-02-24 08:27:43 -05:00
Artem Yavorsky
bc02c95ef0 Fixes #143. Log correct targets. (#155) 2017-01-26 19:53:52 -05:00
Kilian Valkhof
4cefa5bcc0 Use external Electron to Chromium library (#144)
* Replace manual electron-to-chromium list and function with external library

* test fixtures for electron: Switch to electron 1.4, with known chrome version and update expected output

* update tests: electron 1.0 used chrome 49, not 50

* import only the relevant function from electron-to-chromium

* electron fixtures: Use number instead of string

* If both chrome and electron are defined, choose the lower version to preserve

* Add to test cases to verify correct handling of chrome number
2017-01-19 17:41:02 -05:00
Brian Ng
69870774e7 Fix few typos 2017-01-18 19:12:13 -06:00
Eric Baer
05353d5392 Extract option normalization into independant file 2017-01-18 09:01:06 -08:00
Kai Cataldo
ad5698ed19 devDeps: eslint-config-babel v5.0.0 (#139) 2017-01-15 22:34:53 -05:00
Artem Yavorsky
74f2fb17a1 Transformations before logs (#128) 2017-01-10 12:03:07 -05:00
Marco Massarotto
1815ffab14 Explicitly resolve lowest browser version (#121)
stop relying on browserlist returning a list sorted by browser version
fix #119
2017-01-06 17:18:43 -05:00
Brian Ng
76e12a3cae Show error if target version is not a number (#107) 2017-01-02 23:55:32 -05:00
Artem Yavorsky
1fa3916f75 Use parsed targets for Using targets log. 2016-12-23 13:28:33 +02:00
Artem Yavorsky
63c0931340 Make plugin output single-lined. 2016-12-23 13:22:45 +02:00
Artem Yavorsky
c0b8f5b604 Fix targets for debug. 2016-12-23 01:42:30 +02:00
Henry Zhu
da8ed9643b fix debug 2016-12-16 18:03:29 -05:00
Henry Zhu
c6afaa74d4 fix include/exclude for built-ins (#102) 2016-12-16 17:26:15 -05:00
Henry Zhu
7e8fbd5177 fix issue with using Object.values 2016-12-13 18:11:45 -05:00
Henry Zhu
45370e3553 add exclude option, rename whitelist to include (#89) 2016-12-13 16:16:54 -05:00
Eric Baer
e379681b58 Update pathnames to aviod uppercase + consistent with other babel projects 2016-12-12 08:59:52 -05:00
Henry Zhu
8622d0af39 lint [skip ci] 2016-12-12 08:57:51 -05:00
Artem Yavorsky
635e76c85a Optimize result filtration. (#77) 2016-12-12 08:48:18 -05:00
Henry Zhu
44c40cf7ab fix regenerator import (#68) 2016-12-10 10:11:15 -05:00
Henry Zhu
64ed1ba167 add tests for electron option
Closes gh-55
2016-12-09 14:42:26 -05:00
Paul Betts
a38f07181d Map Electron versions to Chromium ones 2016-12-09 14:42:11 -05:00
Henry Zhu
08cd975eb4 always include web polyfills for now 2016-12-09 11:23:46 -05:00
Henry Zhu
d2976bed13 remove console.log, fix tests 2016-12-09 11:23:46 -05:00
Henry Zhu
541ebb5e5f also import regenerator when the transform is required 2016-12-09 11:23:46 -05:00
Henry Zhu
8e2aa82991 also transform 'core-js' 2016-12-09 11:23:46 -05:00
Henry Zhu
5d32ca6bb3 prevent duplicate imports 2016-12-09 11:23:46 -05:00
Artem Yavorsky
99c078e92a Add logs for polyfills. (#59) 2016-12-09 11:23:46 -05:00
Henry Zhu
6ffd13af85 fixes 2016-12-09 11:23:46 -05:00
Henry Zhu
d06270498b add some tests 2016-12-02 17:58:31 -05:00
Henry Zhu
3a7a1b9221 add more features 2016-12-02 16:47:38 -05:00
Henry Zhu
7afe25bda1 change format 2016-12-02 16:04:02 -05:00
Henry Zhu
c09532f035 plugin transforms the imports/requires 2016-12-02 15:33:27 -05:00
Henry Zhu
6c58d93602 setup the babel plugin to transform the babel-polyfill calls + pass the data option to the plugin from the preset 2016-12-02 13:04:21 -05:00
Henry Zhu
60efc0dd10 add useBuiltIns option 2016-12-02 11:43:36 -05:00
Henry Zhu
1115bec3c3 Only console.log the debug info once (#46) 2016-11-16 12:27:39 -05:00
Diogo Franco
d407ddc00c Fix lint 2016-11-11 01:43:21 +09:00
Diogo Franco
cbd827b9db Rename ios_saf in browserslist data to ios, ignore unknown browsers
browserslist queries, especially ones with percentages, often bring in mobile browsers that _probably_ have the similar support level as desktop ones, but since there's no support for them in the data, including them here would just lead to all plugins being enabled always.

It's also easy to get crazy things like `op_mini` or `and_uc` in the results.

Browserslist also reports iOS Safari as `ios_saf`, while the data uses `ios`, so it needs to be renamed.
2016-11-11 01:32:17 +09:00
Henry Zhu
d40c684723 hardcode a current node version option (#35) 2016-11-02 16:17:42 -04:00
Henry Zhu
414acf5fda Change default behavior to act the same as babel-preset-latest (#33)
* Do not throw on empty options, and default to latest preset

* fix lint
2016-11-02 11:57:26 -04:00
Henry Zhu
69e93fdb89 add 'whitelist' option (#31)
Ref https://github.com/babel/babel-preset-env/issues/16
2016-11-02 10:55:45 -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
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
Henry Zhu
4903395cbf remove integer error for node, add debug option (#18) 2016-10-06 23:55:37 -04:00
Henry Zhu
a665d4a5ae update node data, fix version issues (#13) 2016-10-06 22:33:03 -04:00
Ville Immonen
77a6d686ba Build the browser data from ES compatibility table (#8)
Use the data from https://github.com/kangax/compat-table to build the
browser data.

Each Babel plugin is mapped to a list of features in the compatibility
table (in `data/pluginFeatures.js`), and the minimum supporting
version looked up from the compatibility test data. The script builds
the final browser data file in `data/plugins.json`.
2016-10-06 14:23:01 -04:00
Henry Zhu
b4acfc31d9 Fix: export default 2016-09-30 17:41:22 -04:00
Henry Zhu
2c97212fd4 modules/loose opts from es2015 preset, add travis (#6)
* modules/loose opts from es2015 preset, add travis

* Update .travis.yml

* fix plugin function [skip ci]
2016-09-05 23:39:50 -04:00
Eric Baer
78c21a282a Implement very basic (but working) functionality (#3)
* Implement very basic (but working) functionality

* Correct PR based on feedback
2016-09-01 11:55:50 -04:00