1 line
2.9 KiB
JSON
1 line
2.9 KiB
JSON
|
{"ast":null,"code":"\"use strict\";\n\nfunction _createForOfIteratorHelper(o) { if (typeof Symbol === \"undefined\" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) { var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); } var it, normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = inherits;\n\nvar _constants = require(\"../constants\");\n\nvar _inheritsComments = _interopRequireDefault(require(\"../comments/inheritsComments\"));\n\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n\nfunction inherits(child, parent) {\n if (!child || !parent) return child;\n\n var _iterator = _createForOfIteratorHelper(_constants.INHERIT_KEYS.optional),\n _step;\n\n try {\n for (_iterator.s(); !(_step = _iterator.n()).done;) {\n var _key = _step.value;\n\n if (child[_key] == null) {\n child[_key] = parent[_key];\n }\n }\n } catch (err) {\n _iterator.e(err);\n } finally {\n _iterator.f();\n }\n\n for (var _i = 0, _Object$keys = Object.keys(parent); _i < _Object$keys.length; _i++) {\n var key = _Object$keys[_i];\n if (key[0] === \"_\" && key !== \"__clone\") child[key] = parent[key];\n }\n\n var _iterator2 = _createForOfIteratorHelper(_constants.INHERIT_KEYS.force),\n _step2;\n\n try {\n for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {\n var _key2 = _step2.value;\n child[_key2] = parent[_key2];\n }\n } catch (err) {\n _iterator2.e(err);\n } finally {\n _iterator2.f();\n }\n\n (0, _inheritsComments.default)(child, parent);\n return child;\n}","map":null,"metadata":{},"sourceType":"script"}
|