Import ES6 functions and helpers from 6to5-runtime

The new `6to5-runtime` packs core-js, 6to5's helpers and
the Regenerator runtime, and we're moving `coreAliasing`,
`externalRuntime` and `externalRegenerator` to use it
instead of forcing the user to depend on these packages
directly.
This commit is contained in:
Aluísio Augusto Silva Gonçalves
2015-01-18 20:39:35 -02:00
parent e2f4ca106e
commit 8d288c01ca
12 changed files with 12 additions and 13 deletions

View File

@@ -23,7 +23,7 @@ exports.optional = true;
exports.ast = {
enter: function (ast, file) {
file._coreId = file.addImport("core-js/library", "core");
file._coreId = file.addImport("6to5-runtime/core-js", "core");
},
exit: function (ast, file) {

View File

@@ -4,7 +4,7 @@ exports.optional = true;
exports.ast = {
enter: function (ast, file) {
file._regeneratorId = file.addImport("regenerator/runtime-module", "regeneratorRuntime");
file._regeneratorId = file.addImport("6to5-runtime/regenerator", "regeneratorRuntime");
}
};

View File

@@ -5,6 +5,6 @@ exports.optional = true;
// AST is built.
exports.ast = {
enter: function (ast, file) {
file.opts.runtime = file.addImport(file.opts.runtime, "to5Runtime").name;
file.opts.runtime = file.addImport("6to5-runtime/6to5", "to5Runtime").name;
}
};