2.11.87 • Published 12 months ago

@zitterorg/probable-octo v2.11.87

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

@zitterorg/probable-octo Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Which kind of Typed Array is this JavaScript value? Works cross-realm, without instanceof, and despite Symbol.toStringTag.

Example

var whichTypedArray = require('@zitterorg/probable-octo');
var assert = require('assert');

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

assert.equal('Int8Array', whichTypedArray(new Int8Array()));
assert.equal('Uint8Array', whichTypedArray(new Uint8Array()));
assert.equal('Uint8ClampedArray', whichTypedArray(new Uint8ClampedArray()));
assert.equal('Int16Array', whichTypedArray(new Int16Array()));
assert.equal('Uint16Array', whichTypedArray(new Uint16Array()));
assert.equal('Int32Array', whichTypedArray(new Int32Array()));
assert.equal('Uint32Array', whichTypedArray(new Uint32Array()));
assert.equal('Float32Array', whichTypedArray(new Float32Array()));
assert.equal('Float64Array', whichTypedArray(new Float64Array()));
assert.equal('BigInt64Array', whichTypedArray(new BigInt64Array()));
assert.equal('BigUint64Array', whichTypedArray(new BigUint64Array()));

Tests

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

es2015isbannerextensionletdebuggerwatcherES2021bindspinnerreadablestreamposedirectorylinuxajaxtelephonelastcacheReflect.getPrototypeOfpostcss-pluginloggerquotehookformwaitlogTypeBoxhashArray.prototype.findLastIndexbrowserslistspinnersstatustrimStartbootstrap lessbabel-corejsonpathcallbindhascommand-linecensorObject.isrfc4122requestreduxgesturesjQuerycolortoolkitES2020fastclonegetPrototypeOfserializationgetoptmaprecursiveJSONredux-toolkitdragawesomesauceArray.prototype.findLastframerargumentregular expressionduplexIteratoransiRegExp.prototype.flagsinspectObservablelookdotenvtranspilerlockfiledirtaskObject.valuesprivateECMAScript 5stdlibtypemixinsupshebangentriesAsyncIteratorcomparelibphonenumberArray.prototype.containsdefineconcurrencydeep-cloneexit-codeponyfillHyBispeedcallbackURLarraysstylesheetbundlingcontainsworkspace:*redactpolyfillcss variableintrinsicsorted-0package.json_.extendObjectWebSocketArray.prototype.flatMapparentsTypeScriptmergeequalitydom-testing-libraryextendfolderformsgroupreact-testing-libraryenvconcatbufferhttpsdeepRegExp#flagstoobjectincludesworkerprivate dataArray.prototype.filtertypedarraywordwraplazyshamefficientiefastifynumberprocessexitreact-hook-formprogresspromiselinewrapUint8ClampedArrayreact posejson-schemaES2015tc39consoleschemastreamsdeep-copyoncefullwidthcollection.es6columnsarraybuffergdprReactiveExtensionsdebugpnpm9rangeerrorECMAScript 2017formxtermfind-upfixed-widthvestgetintrinsiccryptes2017whichsameValueZeroshellqueueMicrotaskoperating-systemeventDispatchergradients css3ES8lesscsscommanderresolveextramonoreponameimmutablebabelrateYAMLeslintpluginobjsequencebootstrap csstakedatastructurecjkmkdirsvariablesECMAScript 2016mobilequeryerror-handlingstreamdependenciesECMAScript 2023iteratorpackage managertrimestreeES2019jsonschemaCSSStyleDeclarationthrottlelimitnegativecommandpluginsignalspreprocessortranspilePromiseerrorl10ngloblistenersdeepcopyterminalassertionkoreanObject.getPrototypeOf6to5outputsearchcompile lessstreams2chaimacoseast-asian-widthArrayBufferhandlerslintwatchFilecollectiondropcorevalueshelpershigher-orderES2018reducerrobustRFC-6455definePropertylruopenFloat64Arraymkdircircularbddeveryinternalcolorsconstconfigurableavajavascriptvalidatorguidairbnbless csszodbatchkeysstringifytrimRightmiddlewarecharactersoptionclientvariables in cssmakeauthenticationStreamsprotourlsuperagentdescriptionstructuredCloneWebSocketsiteratejsdomflatMapECMAScript 2015tddmimetypesclassnameratelimitwidthflagsqsnested cssFunction.prototype.nameoptimizersymbolseslinteventscolourzerotypedarraysURLSearchParamssetRxJSsafewrapweaksetgraphqlECMAScript 7lengthcsstrimLeftmochaObject.definePropertyquerystringexpressjapanesenamesArrayBuffer.prototype.slicedataViewassertString.prototype.matchAllspringes7flagES5keywordbreakUnderscorestringObservablesinterruptsECMAScript 6matchrgbapolloCSSECMAScript 2021Symbol.toStringTagecmascriptfullcoercible0promisesidleinferenceflataccessibilitytestingunicodeObject.keysbusyjsdiffartES6Uint16ArrayES2023descriptorBigInt64ArraydomECMAScript 2022ES2022MicrosoftSymbolphonecurlfastcopyStreamuuidbundlerargparseString.prototype.trimECMAScript 2018code pointsshrinkwrapminimalmake dires8dateschemefunctionreacttimewatchingfastnodecomputed-typescss nestingeslintconfigsyntaxerrorisConcatSpreadableomitstylehardlinksjoiprunegetterprototypepropertyMapinternal slotthroatirqpreserve-symlinkses2018testfindupviewio-tsautoprefixerObject.assignelectronimmerpipeshimwritees5frameworkbrowserlistclassesless mixinsjson-schema-validatornpm3dmetadataenumerablesortapiformatcliwatchnodejsserializerbrowserutilitieschannelfile systemfigletreadEStrimEndscheme-validationInt8Array
@zitterorg/vel-at-tenetur@zitterorg/amet-porro-impedit@zitterorg/amet-minus@zitterorg/amet-vero-laboriosam@zitterorg/amet-accusamus@zitterorg/animi-accusantium-similique@zitterorg/animi-atque@zitterorg/aliquid-ducimus-provident@zitterorg/asperiores-consectetur@zitterorg/aspernatur-pariatur-occaecati@zitterorg/architecto-dolore@zitterorg/asperiores-molestias@zitterorg/aut-fugit@zitterorg/earum-harum@zitterorg/doloribus-itaque@zitterorg/doloribus-quidem-enim@zitterorg/hic-suscipit@zitterorg/harum-ratione@zitterorg/hic-dicta@zitterorg/illum-perferendis-consectetur@zitterorg/nemo-dolorem@zitterorg/necessitatibus-doloremque@zitterorg/natus-tempora@zitterorg/nemo-tenetur@zitterorg/numquam-itaque@zitterorg/pariatur-ad@zitterorg/perferendis-id@zitterorg/quaerat-error-quae@zitterorg/quasi-corrupti-voluptates@zitterorg/quas-in-suscipit@zitterorg/qui-dicta@zitterorg/quas-autem@zitterorg/quisquam-distinctio-veritatis@zitterorg/quis-maxime@zitterorg/quod-veritatis@zitterorg/ab-fugiat-impedit@zitterorg/a-in@zitterorg/at-esse-odit@zitterorg/consequatur-eius@zitterorg/blanditiis-esse-iusto@zitterorg/corporis-sit@zitterorg/cupiditate-fugiat-culpa@zitterorg/corrupti-animi-beatae@zitterorg/corporis-ut-consectetur@zitterorg/cum-commodi@zitterorg/cum-non@zitterorg/dolor-laboriosam@zitterorg/dolor-nostrum-porro@zitterorg/dolore-quas@zitterorg/distinctio-perferendis@zitterorg/eum-expedita@zitterorg/fugit-ex-neque@zitterorg/impedit-ex-praesentium@zitterorg/inventore-facere@zitterorg/incidunt-voluptas@zitterorg/ipsum-magnam@zitterorg/itaque-nisi-veritatis@zitterorg/itaque-nesciunt-voluptatibus@zitterorg/itaque-sapiente-similique@zitterorg/itaque-ab@zitterorg/occaecati-beatae@zitterorg/quibusdam-sit-qui@zitterorg/quia-sapiente@zitterorg/quibusdam-numquam@zitterorg/rem-iure@zitterorg/repellat-ut@zitterorg/repudiandae-blanditiis@zitterorg/reprehenderit-soluta-ad@zitterorg/repellendus-impedit-repellendus@zitterorg/repudiandae-nihil-architecto@zitterorg/saepe-eos@zitterorg/sint-veritatis@zitterorg/tempore-debitis-minima@zitterorg/sit-expedita@zitterorg/totam-quos-dolorem@zitterorg/unde-exercitationem@zitterorg/velit-dicta@zitterorg/veritatis-repellat-debitis@zitterorg/voluptate-voluptatem@zitterorg/adipisci-quae-eius@zitterorg/accusantium-reprehenderit-quisquam@zitterorg/accusantium-quam@zitterorg/adipisci-ipsum@zitterorg/adipisci-autem@zitterorg/accusamus-quos-consequuntur@zitterorg/aperiam-nisi@zitterorg/consequuntur-perspiciatis@zitterorg/corporis-architecto@zitterorg/consequuntur-illum-corrupti@zitterorg/delectus-nisi-impedit@zitterorg/delectus-est@zitterorg/dolores-perspiciatis-rem@zitterorg/dolores-debitis@zitterorg/doloremque-aspernatur-molestias@zitterorg/dolores-consequatur@zitterorg/doloremque-sed@zitterorg/expedita-quasi@zitterorg/explicabo-iure@zitterorg/facere-id@zitterorg/illo-perspiciatis-animi
2.11.87

12 months ago

2.11.83

1 year ago

2.11.84

12 months ago

2.11.85

12 months ago

2.11.86

12 months ago

2.11.80

1 year ago

2.11.81

1 year ago

2.11.82

1 year ago

2.11.77

1 year ago

2.11.78

1 year ago

2.11.79

1 year ago

2.11.73

1 year ago

2.11.74

1 year ago

2.11.75

1 year ago

2.11.76

1 year ago

2.8.39

1 year ago

2.9.45

1 year ago

2.9.46

1 year ago

2.9.43

1 year ago

2.9.44

1 year ago

2.8.38

1 year ago

2.8.37

1 year ago

2.9.47

1 year ago

2.8.41

1 year ago

2.8.40

1 year ago

2.10.47

1 year ago

2.10.48

1 year ago

2.10.49

1 year ago

2.8.43

1 year ago

2.8.42

1 year ago

2.11.62

1 year ago

2.10.50

1 year ago

2.11.63

1 year ago

2.10.51

1 year ago

2.11.64

1 year ago

2.10.52

1 year ago

2.11.65

1 year ago

2.10.53

1 year ago

2.11.66

1 year ago

2.10.54

1 year ago

2.11.67

1 year ago

2.10.55

1 year ago

2.11.68

1 year ago

2.10.56

1 year ago

2.11.69

1 year ago

2.10.57

1 year ago

2.10.58

1 year ago

2.10.59

1 year ago

2.11.70

1 year ago

2.11.71

1 year ago

2.11.72

1 year ago

2.10.60

1 year ago

2.10.61

1 year ago

2.10.62

1 year ago

2.8.36

1 year ago

2.7.33

1 year ago

2.7.36

1 year ago

2.7.35

1 year ago

2.7.34

1 year ago

2.6.31

1 year ago

2.6.32

1 year ago

2.7.32

1 year ago

1.5.30

1 year ago

1.5.31

1 year ago

1.4.26

1 year ago

1.4.25

1 year ago

1.4.28

1 year ago

1.4.27

1 year ago

1.4.29

1 year ago

1.3.24

1 year ago

1.3.25

1 year ago

1.3.23

1 year ago

1.5.29

1 year ago

2.5.31

1 year ago

1.3.21

1 year ago

1.3.22

1 year ago

1.2.18

1 year ago

1.2.19

1 year ago

1.2.20

1 year ago

1.2.21

1 year ago

1.2.17

1 year ago

1.2.16

1 year ago

1.2.15

1 year ago

1.2.14

1 year ago

1.2.13

1 year ago

1.2.12

1 year ago

1.2.11

1 year ago

1.2.10

1 year ago

1.2.9

1 year ago

1.2.8

1 year ago

1.2.7

1 year ago

1.2.6

1 year ago

1.2.5

1 year ago

1.1.5

1 year ago

1.1.4

1 year ago

1.1.3

1 year ago

1.1.2

1 year ago

1.1.1

1 year ago

1.1.0

1 year ago