UNPKG

452 BJavaScriptView Raw
1import _Reflect$construct from "core-js/library/fn/reflect/construct.js";
2import setPrototypeOf from "./setPrototypeOf.js";
3import isNativeReflectConstruct from "./isNativeReflectConstruct.js";
4export default function _construct(t, e, r) {
5 if (isNativeReflectConstruct()) return _Reflect$construct.apply(null, arguments);
6 var o = [null];
7 o.push.apply(o, e);
8 var p = new (t.bind.apply(t, o))();
9 return r && setPrototypeOf(p, r.prototype), p;
10}
\No newline at end of file