Split @babel/runtime into two separate runtime modules.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# @babel/runtime
|
||||
|
||||
> babel selfContained runtime
|
||||
> babel's modular runtime helpers
|
||||
|
||||
See our website [@babel/runtime](https://babeljs.io/docs/en/next/babel-runtime.html) for more information.
|
||||
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
module.exports = require("core-js/library");
|
||||
@@ -1 +0,0 @@
|
||||
module.exports = require("core-js/library/fn/map");
|
||||
@@ -1,5 +0,0 @@
|
||||
function _iterableToArray(iter) {
|
||||
if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter);
|
||||
}
|
||||
|
||||
module.exports = _iterableToArray;
|
||||
@@ -1,11 +0,0 @@
|
||||
var temporalUndefined = require("./temporalUndefined");
|
||||
|
||||
function _temporalRef(val, name) {
|
||||
if (val === temporalUndefined) {
|
||||
throw new ReferenceError(name + " is not defined - temporal dead zone");
|
||||
} else {
|
||||
return val;
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = _temporalRef;
|
||||
@@ -1,11 +0,0 @@
|
||||
var arrayWithHoles = require("./arrayWithHoles");
|
||||
|
||||
var iterableToArray = require("./iterableToArray");
|
||||
|
||||
var nonIterableRest = require("./nonIterableRest");
|
||||
|
||||
function _toArray(arr) {
|
||||
return arrayWithHoles(arr) || iterableToArray(arr) || nonIterableRest();
|
||||
}
|
||||
|
||||
module.exports = _toArray;
|
||||
@@ -1,5 +0,0 @@
|
||||
import _Array$from from "../../core-js/array/from";
|
||||
import _isIterable from "../../core-js/is-iterable";
|
||||
export default function _iterableToArray(iter) {
|
||||
if (_isIterable(Object(iter)) || Object.prototype.toString.call(iter) === "[object Arguments]") return _Array$from(iter);
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
import undef from "./temporalUndefined";
|
||||
export default function _temporalRef(val, name) {
|
||||
if (val === undef) {
|
||||
throw new ReferenceError(name + " is not defined - temporal dead zone");
|
||||
} else {
|
||||
return val;
|
||||
}
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
import arrayWithHoles from "./arrayWithHoles";
|
||||
import iterableToArray from "./iterableToArray";
|
||||
import nonIterableRest from "./nonIterableRest";
|
||||
export default function _toArray(arr) {
|
||||
return arrayWithHoles(arr) || iterableToArray(arr) || nonIterableRest();
|
||||
}
|
||||
@@ -1,9 +1,5 @@
|
||||
var _Array$from = require("../core-js/array/from");
|
||||
|
||||
var _isIterable = require("../core-js/is-iterable");
|
||||
|
||||
function _iterableToArray(iter) {
|
||||
if (_isIterable(Object(iter)) || Object.prototype.toString.call(iter) === "[object Arguments]") return _Array$from(iter);
|
||||
if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter);
|
||||
}
|
||||
|
||||
module.exports = _iterableToArray;
|
||||
@@ -1,12 +1,11 @@
|
||||
{
|
||||
"name": "@babel/runtime",
|
||||
"version": "7.0.0-beta.55",
|
||||
"description": "babel selfContained runtime",
|
||||
"description": "babel's modular runtime helpers",
|
||||
"license": "MIT",
|
||||
"repository": "https://github.com/babel/babel/tree/master/packages/babel-runtime",
|
||||
"author": "Sebastian McKenzie <sebmck@gmail.com>",
|
||||
"dependencies": {
|
||||
"core-js": "^2.5.7",
|
||||
"regenerator-runtime": "^0.12.0"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user