Allow extending untranspiled classes (#8656)

This commit is contained in:
Nicolò Ribaudo
2020-03-16 23:59:15 +01:00
committed by GitHub
parent a875560c31
commit f6c7bf36ce
152 changed files with 1013 additions and 265 deletions

View File

@@ -1,15 +1,22 @@
import _Reflect$construct from "@babel/runtime-corejs2/core-js/reflect/construct";
import _classCallCheck from "@babel/runtime-corejs2/helpers/esm/classCallCheck";
import _possibleConstructorReturn from "@babel/runtime-corejs2/helpers/esm/possibleConstructorReturn";
import _getPrototypeOf from "@babel/runtime-corejs2/helpers/esm/getPrototypeOf";
import _inherits from "@babel/runtime-corejs2/helpers/esm/inherits";
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = _Reflect$construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_Reflect$construct) return false; if (_Reflect$construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(_Reflect$construct(Date, [], function () {})); return true; } catch (e) { return false; } }
let Foo = /*#__PURE__*/function (_Bar) {
_inherits(Foo, _Bar);
var _super = _createSuper(Foo);
function Foo() {
_classCallCheck(this, Foo);
return _possibleConstructorReturn(this, _getPrototypeOf(Foo).apply(this, arguments));
return _super.apply(this, arguments);
}
return Foo;

View File

@@ -1,15 +1,22 @@
import _Reflect$construct from "@babel/runtime-corejs2/core-js/reflect/construct";
import _classCallCheck from "@babel/runtime-corejs2/helpers/classCallCheck";
import _possibleConstructorReturn from "@babel/runtime-corejs2/helpers/possibleConstructorReturn";
import _getPrototypeOf from "@babel/runtime-corejs2/helpers/getPrototypeOf";
import _inherits from "@babel/runtime-corejs2/helpers/inherits";
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = _Reflect$construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_Reflect$construct) return false; if (_Reflect$construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(_Reflect$construct(Date, [], function () {})); return true; } catch (e) { return false; } }
let Foo = /*#__PURE__*/function (_Bar) {
_inherits(Foo, _Bar);
var _super = _createSuper(Foo);
function Foo() {
_classCallCheck(this, Foo);
return _possibleConstructorReturn(this, _getPrototypeOf(Foo).apply(this, arguments));
return _super.apply(this, arguments);
}
return Foo;

View File

@@ -6,15 +6,21 @@ var _getPrototypeOf = require("@babel/runtime/helpers/getPrototypeOf");
var _inherits = require("@babel/runtime/helpers/inherits");
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
let Foo = /*#__PURE__*/function (_Bar) {
"use strict";
_inherits(Foo, _Bar);
var _super = _createSuper(Foo);
function Foo() {
_classCallCheck(this, Foo);
return _possibleConstructorReturn(this, _getPrototypeOf(Foo).apply(this, arguments));
return _super.apply(this, arguments);
}
return Foo;

View File

@@ -6,15 +6,21 @@ var _getPrototypeOf = require("@babel/runtime/helpers/getPrototypeOf");
var _inherits = require("@babel/runtime/helpers/inherits");
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
let Foo = /*#__PURE__*/function (_Bar) {
"use strict";
_inherits(Foo, _Bar);
var _super = _createSuper(Foo);
function Foo() {
_classCallCheck(this, Foo);
return _possibleConstructorReturn(this, _getPrototypeOf(Foo).apply(this, arguments));
return _super.apply(this, arguments);
}
return Foo;

View File

@@ -3,13 +3,19 @@ import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConst
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
import _inherits from "@babel/runtime/helpers/esm/inherits";
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
let Foo = /*#__PURE__*/function (_Bar) {
_inherits(Foo, _Bar);
var _super = _createSuper(Foo);
function Foo() {
_classCallCheck(this, Foo);
return _possibleConstructorReturn(this, _getPrototypeOf(Foo).apply(this, arguments));
return _super.apply(this, arguments);
}
return Foo;

View File

@@ -3,13 +3,19 @@ import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConst
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
import _inherits from "@babel/runtime/helpers/esm/inherits";
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
let Foo = /*#__PURE__*/function (_Bar) {
_inherits(Foo, _Bar);
var _super = _createSuper(Foo);
function Foo() {
_classCallCheck(this, Foo);
return _possibleConstructorReturn(this, _getPrototypeOf(Foo).apply(this, arguments));
return _super.apply(this, arguments);
}
return Foo;