UNPKG

is-array-x

Version:

Determines whether the passed value is an Array.

15 lines 6.11 kB
/*! { "author": "Graham Fairweather", "copywrite": "Copyright (c) 2017-present", "date": "2019-08-28T17:11:59.864Z", "describe": "", "description": "Determines whether the passed value is an Array.", "file": "is-array-x.min.js", "hash": "5e931c2fd3a4b05a2a57", "license": "MIT", "version": "2.1.2" } */ !function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.isArrayX=n():t.isArrayX=n()}(function(){"use strict";var t,n={}.constructor,r=n.prototype,e=n.defineProperty,o=function(){return"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:void 0},u=function(){return this};try{return e?e(r,"$$globalThis$$",{get:u,configurable:!0}):r.__defineGetter__("$$globalThis$$",u),t="undefined"==typeof $$globalThis$$?o():$$globalThis$$,delete r.$$globalThis$$,t}catch(t){return o()}}(),function(){return function(t){var n={};function r(e){if(n[e])return n[e].exports;var o=n[e]={i:e,l:!1,exports:{}};return t[e].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=t,r.c=n,r.d=function(t,n,e){r.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:e})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,n){if(1&n&&(t=r(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var e=Object.create(null);if(r.r(e),Object.defineProperty(e,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var o in t)r.d(e,o,function(n){return t[n]}.bind(null,o));return e},r.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(n,"a",n),n},r.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},r.p="",r(r.s=1)}([function(t,n,r){"use strict";var e=String.prototype.valueOf,o=Object.prototype.toString,u="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag;t.exports=function(t){return"string"==typeof t||"object"==typeof t&&(u?function(t){try{return e.call(t),!0}catch(t){return!1}}(t):"[object String]"===o.call(t))}},function(t,n,r){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}r.r(n);var o=function(t){return"object"===e(t)?null===t:"function"!=typeof t},u=r(0),i=r.n(u),f={}.constructor("a"),c="a"===f[0]&&0 in f,l=function(){}.bind,a="function"==typeof l&&function(){var t=null,n=null,r=null,e=[];try{var o=l.apply(function(e,o){return r=this,t=e,n=o,arguments},[e,1]),u=o(2);return 1===o.length&&2===u.length&&1===t&&2===n&&r===e}catch(t){return!1}}()&&function(){var t=null,n=null,r=null,e=[1,2,3],o=function(o,u){return t=o,n=u,r=this,e};try{var u=l.apply(o,[null]),i=new u(1,2);return u.length===o.length&&i===e&&1===t&&2===n&&r!==e}catch(t){return!1}}(),p="".split,y=Math.max,s=o.bind,b=o.call,d=a?s.call(b,p):function(t,n){return p.call(t,n)},h=function(t){return i()(t)?d(t,""):t},g=function(t,n){var r=arguments.length>2?arguments[2]:[];if("string"!=typeof t&&o(t))return r;for(var e=c?t:h(t),u=e.length,i=y(0,n)||0;i<u;i+=1)r[r.length]=t[i];return r};function v(t,n){return function(t){if(Array.isArray(t))return t}(t)||function(t,n){var r=[],e=!0,o=!1,u=void 0;try{for(var i,f=t[Symbol.iterator]();!(e=(i=f.next()).done)&&(r.push(i.value),!n||r.length!==n);e=!0);}catch(t){o=!0,u=t}finally{try{e||null==f.return||f.return()}finally{if(o)throw u}}return r}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}var m=g.bind,S=g.call,j={},$=j.constructor,w=j.toString,x=function(t,n){return t>=n?t:n},T=function(t){if("function"!=typeof t&&"[object Function]"!==w.apply(t))throw new TypeError("bind called on incompatible "+t)},_=[function(t){return function(){return t.apply(this,g(arguments))}},function(t,n){return function(r){return t.apply(this,g(arguments,n,[r]))}},function(t,n){return function(r,e){return t.apply(this,g(arguments,n,[r,e]))}},function(t,n){return function(r,e,o){return t.apply(this,g(arguments,n,[r,e,o]))}},function(t,n){return function(r,e,o,u){return t.apply(this,g(arguments,n,[r,e,o,u]))}},function(t,n){return function(r,e,o,u,i){return t.apply(this,g(arguments,n,[r,e,o,u,i]))}},function(t,n){return function(r,e,o,u,i,f){return t.apply(this,g(arguments,n,[r,e,o,u,i,f]))}},function(t,n){return function(r,e,o,u,i,f,c){return t.apply(this,g(arguments,n,[r,e,o,u,i,f,c]))}},function(t,n){return function(r,e,o,u,i,f,c,l){return t.apply(this,g(arguments,n,[r,e,o,u,i,f,c,l]))}}],O=function(t){var n=v(t,3),r=n[0],e=n[1],o=n[2],u=x(0,e.length-x(0,o.length-2)),i=_[u],f=i?i(r,u):_[0](r);if(e.prototype){var c=function(){};c.prototype=e.prototype,f.prototype=new c,c.prototype=null}return f},A=function(t,n){var r=t.apply(this,n);return $(r)===r?r:this},P=a?S.bind(m):function(t,n){T(t);var r,e=arguments,o=function(){var o=g(arguments,0,g(e,2));return this instanceof r?A.apply(this,[t,o]):t.apply(n,o)};return r=O([o,t,e])},M=TypeError,E=P.apply,F=P(P.call,E),X=P(E,{}.toString),z=function(t){if("function"!=typeof t&&"[object Function]"!==X(t))throw new M(t+" is not a function");return t},G=function(t,n){return F(z(t),n,g(arguments[2]))},I=function(t){try{return{threw:!1,value:G(t,this,g(arguments,1))}}catch(t){return{threw:!0,value:t}}},N={}.toString,U=function(t){return function(t){if("function"!=typeof t&&"[object Function]"!==G(N,t))throw new TypeError("methodize called on incompatible "+t)}(t),function(){return G(t,arguments[0],g(arguments,1))}}({}.toString),k=function(t){return null===t?"[object Null]":void 0===t?"[object Undefined]":U(t)};r.d(n,"implementation",function(){return H});var q=[].isArray,B="function"==typeof q&&q,C=I(function(){return!0===B([])&&!1===B({length:0})}),D=!1===C.threw&&!0===C.value,H=function(t){return"[object Array]"===k(t)},J=D?B:H;n.default=J}])}); //# sourceMappingURL=is-array-x.min.js.map