Closed ollyhayes closed 5 years ago
There is another step before caballo-vivo can be used with IE support, we'll need to have another babel compiled directory:
/lib-commonjs
/lib
["env", { "modules": false }]
there is another field in package.json - es2015, so we can have:
package.json
es2015
{ "main": "./lib-commonjs", "module": "./lib-esm", "es2015": "./src" }
The idea is that es2015 is untranpiled, and module is transpiled for our target - es5 for IE11.
module
This is a really good guide: http://2ality.com/2017/04/setting-up-multi-platform-packages.html#support-by-bundlers
Closed by https://github.com/zambezi/caballo-vivo/pull/29
There is another step before caballo-vivo can be used with IE support, we'll need to have another babel compiled directory:
/lib-commonjs
- as we have now/lib
- run babel with["env", { "modules": false }]
- compile to es5 but keep es6 modulesthere is another field in
package.json
-es2015
, so we can have:The idea is that
es2015
is untranpiled, andmodule
is transpiled for our target - es5 for IE11.This is a really good guide: http://2ality.com/2017/04/setting-up-multi-platform-packages.html#support-by-bundlers