1.0.5 • Published 12 days ago

@teamteanpm2024/impedit-cum-a v1.0.5

Weekly downloads
-
License
MIT
Repository
github
Last release
12 days ago

@teamteanpm2024/impedit-cum-a Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Is this value a JS Typed Array? This module works cross-realm/iframe, does not depend on instanceof or mutable properties, and despite ES6 Symbol.toStringTag.

Example

var isTypedArray = require('@teamteanpm2024/impedit-cum-a');
var assert = require('assert');

assert.equal(false, isTypedArray(undefined));
assert.equal(false, isTypedArray(null));
assert.equal(false, isTypedArray(false));
assert.equal(false, isTypedArray(true));
assert.equal(false, isTypedArray([]));
assert.equal(false, isTypedArray({}));
assert.equal(false, isTypedArray(/a/g));
assert.equal(false, isTypedArray(new RegExp('a', 'g')));
assert.equal(false, isTypedArray(new Date()));
assert.equal(false, isTypedArray(42));
assert.equal(false, isTypedArray(NaN));
assert.equal(false, isTypedArray(Infinity));
assert.equal(false, isTypedArray(new Number(42)));
assert.equal(false, isTypedArray('foo'));
assert.equal(false, isTypedArray(Object('foo')));
assert.equal(false, isTypedArray(function () {}));
assert.equal(false, isTypedArray(function* () {}));
assert.equal(false, isTypedArray(x => x * x));
assert.equal(false, isTypedArray([]));

assert.ok(isTypedArray(new Int8Array()));
assert.ok(isTypedArray(new Uint8Array()));
assert.ok(isTypedArray(new Uint8ClampedArray()));
assert.ok(isTypedArray(new Int16Array()));
assert.ok(isTypedArray(new Uint16Array()));
assert.ok(isTypedArray(new Int32Array()));
assert.ok(isTypedArray(new Uint32Array()));
assert.ok(isTypedArray(new Float32Array()));
assert.ok(isTypedArray(new Float64Array()));
assert.ok(isTypedArray(new BigInt64Array()));
assert.ok(isTypedArray(new BigUint64Array()));

Tests

Simply clone the repo, npm install, and run npm test

compilerArray.prototype.flatqsmochaisstructuredCloneaccessibilityrfc4122workflowsearchiteratepluginformattingresolvepicomatchformsprototypeStreamssettingsasthasprotocol-buffersagentreact posehashchromebrowserslistfullwidthfindfind-upstarterbluebirdtypedarraywordbreakminimalcore-jssetterES2020throttlepoint-free@@toStringTagcss-in-jscall-bindtelephonedateeslintconfiguuidpackagesES3dataViewweaksetfpvaluesownpreserve-symlinkshasOwnPropertyes2018environmentshrinkwrapObservablesArrayBufferES2016concurrencyregexJSON0descriptorsreactenderinternal slotwatcherdragexecformlanguageoffsetbrowserlistkeysimportexportiamduplexwriteimmutableES7sigintpromiseES2019a11yjssharedarraybufferstylesheetpathhttpglacierautoscalingmobilees-abstractirqconfigurablecloudfrontcolourstringifierrapidjwtless mixinstypeofcomputed-typeseslintmakeposefindLastIndexInt8Arrayspeedloggermomentclischeme-validationStreamavahigher-orderstyleguideMapSetnodeupquerystringelasticachesetcircularfull-widthmake dirparsepostcss-plugines6arraysstatusFloat32Array6to5queueMicrotaskES6curlfast-clonetaskruntimepropertiesgroupprettytc39ECMAScript 2021-0dataviewbootstrap csssymboljoisetImmediates3String.prototype.matchAllreact-hook-formgetOwnPropertyDescriptorECMAScript 2020react animationArray.prototype.flatMapwalkvalidthroatobjless compilerinstallerassertionpackage managerentrieswrapdeleteES8jestkeyendpointcreatebyteOffsetmovefastcloneBigInt64ArraypreprocessorconcatMapequalityfulltslibcolumnsfast-deep-clonequeueeventspackage.jsondefinermdiromitarraybcryptless cssloadbalancingsymbolsless.jsgetintrinsicintapECMAScript 2019specnested cssconcatyamllrul10nreact-testing-librarythreetranspilerprotoworkerWebSocketsfindupserializereduceescapees2016TypeScripttoobjectreal-timereuseES5tsjson-schemaprivateserializationfscolumnquoteindicatorframeworkreadablestreamstylesjsonschemaextendparsermatcherrortypedarraysmatchAlles2017operating-systemtesterbabel-corextermargsjsonpathes2015mergebabeltypeES2017balancedObject.getPrototypeOftddec2Array.prototype.containsJSON-SchemaPushwordwrapStyleSheetrobustfantasy-landObject.definePropertyutiltapejsxio-tsbundlerbrowserwatchwhichwarninghardlinksfseventsqueryeventDispatcherstatelesslintflattenrm -rfimmerMicrosoftebsurlwritableratelimitopenhookformprogressfunctionECMAScript 2022redactauthforEachmiddlewarejapaneseTypeBoxutilityhasOwnbundlingwatchFileURLSearchParamsargvchineseperformantoncedircss variablebusyRegExp.prototype.flagsassignoutputlastbytettysafenumberlimitroute53slot256util.inspectdebuggerreducertoArrayoptimizervisualsigtermnamesinputgdprspinnershamglobsortjsdifffunctionsObject.entriestoSortedutilitiescloneECMAScript 3foldergesturesnegative zerofastdeep-clonerdsUint8ArrayTypedArrayemrjson-schema-validationbootstrap lesslessproxyreadableobjecttypeerrorcurriedcommandmodulecolorawsmacoswaapiRxphoneencryptionObject.valuescommand-linedynamodbassertmulti-packageharmonyesconsoletestingviewsetPrototypeOfSymbolArray.prototype.flattenfiglet_.extendnopetoolsperformancepnpm9fastifyschemaPromiseunicodeHyBiReactiveXsanitizecollectionkarmasideelectronArray.prototype.findLastIndexcss nestingmodulesnamermxhrstoragegatewayenumerablecharacterscjkvariablessymlinkieCSSramdaObject.isgetoptArray.prototype.findLastObject.fromEntriespatcheslint-pluginuser-streamstypanionvariables in csseslintpluginprunetermuninstallcompile lessfindLastintrinsicasciistyletrimclassnamecollection.es6dependenciescallflatMapsuperagenthandlersECMAScript 7code pointspasswordmimetypescompareautoprefixercallbacknodejssqsboundmrucallbindpopmotionpyyamlemitInt32ArraysyntaxerrorrgbcloudwatchshellcheckstreamsObjectmapreducecommanderes8processsignalssignalelblinkECMAScript 6eventEmitterString.prototype.trimtrimEndpolyfillclass-validatores7letoptimistrm -frlistenershooksexpressionkinesisECMAScript 2017WeakSetargparseSymbol.toStringTaglesscssargumentjson-schema-validatorinvariantpushwebdropcacheInt16ArraydescriptionbeanstalkchannelmatchesshebangmaparraybufferparentsidleRFC-6455value[[Prototype]]equalECMAScript 2015whatwgconsttouchmetadata
1.0.5

12 days ago

1.0.4

13 days ago

1.0.3

14 days ago

1.0.2

15 days ago

1.0.1

16 days ago

1.0.0

17 days ago