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:
@@ -1,6 +1,6 @@
|
||||
"use strict";
|
||||
|
||||
var _core = require("core-js/library");
|
||||
var _core = require("6to5-runtime/core-js");
|
||||
|
||||
obj.constructor === Object;
|
||||
obj.constructor === _core.Promise;
|
||||
|
||||
@@ -16,7 +16,7 @@ var _slicedToArray = function (arr, i) {
|
||||
}
|
||||
};
|
||||
|
||||
var _core = require("core-js/library");
|
||||
var _core = require("6to5-runtime/core-js");
|
||||
|
||||
var _ref = ["hello", [", ", "junk"], ["world"]];
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
"use strict";
|
||||
|
||||
var _core = require("core-js/library");
|
||||
var _core = require("6to5-runtime/core-js");
|
||||
|
||||
for (var _iterator = _core.$for.getIterator(arr), _step; !(_step = _iterator.next()).done;) {
|
||||
var i = _step.value;
|
||||
|
||||
@@ -4,6 +4,6 @@ var _toArray = function (arr) {
|
||||
return Array.isArray(arr) ? arr : _core.Array.from(arr);
|
||||
};
|
||||
|
||||
var _core = require("core-js/library");
|
||||
var _core = require("6to5-runtime/core-js");
|
||||
|
||||
var lyrics = ["head", "and", "toes"].concat(_toArray(parts));
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
"use strict";
|
||||
|
||||
var _core = require("core-js/library");
|
||||
var _core = require("6to5-runtime/core-js");
|
||||
|
||||
var arr = (function () {
|
||||
var _arr = [];
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
"use strict";
|
||||
|
||||
var _regeneratorRuntime = require("regenerator/runtime-module");
|
||||
var _regeneratorRuntime = require("6to5-runtime/regenerator");
|
||||
|
||||
void _regeneratorRuntime.mark(function callee$0$0() {
|
||||
return _regeneratorRuntime.wrap(function callee$0$0$(context$1$0) {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
define(["exports", "6to5-runtime", "someModule"], function (exports, _to5Runtime2, _someModule) {
|
||||
define(["exports", "6to5-runtime/6to5", "someModule"], function (exports, _to5Runtime6to5, _someModule) {
|
||||
"use strict";
|
||||
|
||||
var _to5Runtime = _to5Runtime2;
|
||||
var _to5Runtime = _to5Runtime6to5;
|
||||
var foo = _to5Runtime.interopRequire(_someModule);
|
||||
});
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
"use strict";
|
||||
|
||||
var _to5Runtime = require("6to5-runtime");
|
||||
var _to5Runtime = require("6to5-runtime/6to5");
|
||||
|
||||
var foo = _to5Runtime.interopRequireWildcard(require("someModule"));
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
{
|
||||
"runtime": "6to5-runtime",
|
||||
"optional": ["externalRuntime"]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user