isNativeReflectConstruct.js 455 B

12345678910111213
  1. import _Reflect$construct from "@babel/runtime-corejs3/core-js/reflect/construct";
  2. export default function _isNativeReflectConstruct() {
  3. if (typeof Reflect === "undefined" || !_Reflect$construct) return false;
  4. if (_Reflect$construct.sham) return false;
  5. if (typeof Proxy === "function") return true;
  6. try {
  7. Boolean.prototype.valueOf.call(_Reflect$construct(Boolean, [], function () {}));
  8. return true;
  9. } catch (e) {
  10. return false;
  11. }
  12. }