4.9.97 • Published 12 months ago

@diotoborg/non-hic-magnam v4.9.97

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

@diotoborg/non-hic-magnam 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('@diotoborg/non-hic-magnam');
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

flattenexectoolkitextramodulefixed-widthlistenersprefixvaluesinspectchromesiginteffect-tsguidslicemergecensorvalidatebddprotoreact-hooksdatastructurematchAllobjectES2019package managerspawnglacierWebSocketexpressiondefinemobilenodejses6Streamsjestless mixinsdescriptionspecpathstatelesschannelbinariesenvTypedArraybabel$.extendsignedexecfilewgetcloudformationtrimEndsnsspeeddescriptorsimmerclass-validatorpreprocessorlruefficientgetterbyteOffsetswfArraytddlastapollosortedSymbol.toStringTagtrimRightdateiamdirectorymomenttoStringTagslotfindLastObject.assignassignvalidgroupBystylesheet[[Prototype]]acornsuperstructfastcopycss nestinglessdeletegetshrinkwrapfastlivepropertyperformanceUint8ArrayjsdomastapiirqUint32ArrayReflect.getPrototypeOfes8reverseRegExp.prototype.flagsfromshebangprocessObjectremovereversedcommand-linesyntaxcompile lessloggingpyyamlnamecallbindimmutablewaf-0statusES2015queuelockfileInt8ArraywalkfullwidthmkdirmatchURLSearchParamsroutewritablehookformhashArrayBuffer#sliceStreamObject.definePropertyajaxtoSortedtextsigtermreact-hook-formprototypegetOwnPropertyDescriptorRxJSttyparsingenderisConcatSpreadabletypeofencryptionclasseses-shim APIsuperagentnumberuser-streamstacitreact animationpushwaapifslibphonenumberCSSStyleDeclarationemrpatchflatoptimistdefinePropertyES2021form-validationchromiuminferencerandomarktypeObject.getPrototypeOfUint8ClampedArraybusybyteLengtheventEmittersymlinkeverykinesisECMAScript 7globgdprimportfpsArray.prototype.flatMapArray.prototype.filterrangeerrores2017emitArray.prototype.containsexecutechaicomputed-typeswindowspnpm9argvfunction.lengthtoArrayextendcurlmkdirpboundes2015callboundES2016oncenpmignoreloadbalancingmonorepostreamstypaniondependenciesnativeargumentletpredictablei18ninscheme-validationxhrdependency managerhasprivate datautilrobustsharedarraybuffersesCSStrimfind_.extenderror-handlingtoobjectdom-testing-libraryECMAScript 3ES2020interrupts3dcontainsECMAScript 2015installfindLastIndexECMAScript 2020checktypedfast-deep-copyaccessortranspilersharednodecolumnsES2023cloudfrontiemapstyled-componentsHyBicachearraysreducebannerbuffersReactiveExtensionschildsortminimalhigher-orderyamlrfc4122coerciblePromiseArrayBuffer.prototype.slicegetintrinsicshellcss-in-jscss variablecollection.es6Function.prototype.namecorees-shimstelephoneRegExp#flagsruntimeprivateinternal slotflagsendpointinputredux-toolkitcompilerserializationcolumnoffsetflatMapsignalsdeepclonefastifyES3functionspringstarternameshttpsmixinsfluxreactwindowreact posecloudtrailzxdescriptorbrowserslistes2016a11yreducersyntaxerrortransportcoloursettingsredactrulesiteratorcloneserializeStyleSheetartinvariantforEachmulti-packagereadassertscjkmetadatastyleguidegetPrototypeOfcolordiffjson-schema-validationtypedarrayviewglobal objectpolyfillECMAScript 2017timeserializerargsutilitiesformattingglobalssubprocessMapPushworkerjsxprogressregular expressionrgbtoReversedArray.prototype.flatclassnamesiterationpreserve-symlinkswidthpopmotionhas-ownstringjshinttestingnopetoolsBigUint64ArrayassertmapreduceES2017Uint16ArrayjQueryTypeScriptInt16ArrayReactiveXJSONeventsstate__proto__URLbytecircularpasswordframeruuiditerategesturescall-boundoutputloggertostringtagwriteimportexportcreateregular-expressionrequestdircryptassertionresolveequalitySetintrinsicdotenvreact-componentwhichdeep-copyhttpconfigurableWebSocketstraversetc39asyncauthenticationspinnerbundlerObject.valuesconsumeasciicommandECMAScript 2019esglobal this valueurldeepcopystylinglengthcallbackjwtcloudwatchisgetoptfigletformatfunctionalpackage.jsonwait@@toStringTagvalidationgenericsformsglobalThisFloat32ArrayconcatMapbootstrap less.envconcatdeeprecursivefast-clonepostcssstylesfullweaksetdeterministicforkyupbinmkdirseslintsafevariablescliJSON-SchemaenvironmentstermES2018gradients css3parseridletsreadablesetlanguagefile systemselfconstroute530typescriptcolorsramdafast-copylocalflaggitignorevartouchoptimizererrordragschemabcryptjsdiffmacoscryptoArrayBufferponyfillzerojstypesidepropertiesless cssfilterjsonschemaObject.isenumerableopenssllinkWeakSetcall-bindcliententriesestreecss lesshelperreal-timeamazonelbarraybufferoptionlinux256streamdayjsstringifiersequencechineseprettyvisuales-abstractebskeyquerynpmcsscertificatesrequireArray.prototype.findLastautoscalingTypeBoxglobalinternalterminalpureES2022elmphonesymlinksfastclonedomlazyuninstallawspinoincludeseslintconfigInt32ArraydatathreeomitmruvpcenvironmentdataViewbindpositivestructuredCloneES6symbolsES8core-jspoint-freeconfigansipromisees2018protobuftranspileObservableUnderscorecommandermanagerjson-schemahooksprunereadablestreamwarningpostcss-plugintypesqueueMicrotasksetterecmascriptharmonynegative zeroES5shamformfast-deep-clonevalidatorbuffercloudsearchhandlerspropvariables in cssshimlesscss6to5ECMAScript 2016hotequalawesomesauceasterisksECMAScript 2021rfc9562lintESnexthelpersspinnerspersistentString.prototype.trimregularmakeelectroncodesfantasy-landgroupYAMLjsoneslintpluginignorelogstablewhatwges5operating-systemObject.keysplugintrimLeftBigInt64Arraydeep-clonecharacterObservablestesterfetch.gitignorejapanesesignalrdsexpressgraphqlunicodestoragegatewayajvnegativevarssimpledbRxhasOwnweakmapbinarybundlingString.prototype.matchAllArray.prototype.findLastIndexxtermutil.inspectkoreanzodschemeArray.prototype.includesproxydataviewregexpownauthkeyssqsreact-testing-libraryaccessibilityjoiECMAScript 6l10nESes7MicrosoftbrowserlistmodulescollectionObject.fromEntriesdropeventDispatcherfunctionsexitfphasOwnPropertyairbnbfiletypeerrorES7picomatchutilityec2protocol-buffersWeakMapvestECMAScriptstringify
4.9.97

12 months ago

4.9.96

12 months ago

4.9.95

12 months ago

4.9.94

1 year ago

4.9.93

1 year ago

4.9.92

1 year ago

4.9.91

1 year ago

4.9.90

1 year ago

4.9.89

1 year ago

4.9.88

1 year ago

4.9.87

1 year ago

4.9.86

1 year ago

4.9.85

1 year ago

4.9.84

1 year ago

4.9.83

1 year ago

4.9.82

1 year ago

4.9.81

1 year ago

4.9.80

1 year ago

4.9.79

1 year ago

4.9.78

1 year ago

4.9.77

1 year ago

4.9.76

1 year ago

4.9.75

1 year ago

4.8.75

1 year ago

4.8.74

1 year ago

4.8.73

1 year ago

4.8.72

1 year ago

4.8.71

1 year ago

4.8.70

1 year ago

4.7.70

1 year ago

4.6.70

1 year ago

3.6.70

1 year ago

3.6.69

1 year ago

3.6.68

1 year ago

3.6.67

1 year ago

3.6.66

1 year ago

3.6.65

1 year ago

3.6.64

1 year ago

3.6.63

1 year ago

3.6.62

1 year ago

3.5.62

1 year ago

3.5.61

1 year ago

3.5.60

1 year ago

3.5.59

1 year ago

3.5.58

1 year ago

3.5.57

1 year ago

3.5.56

1 year ago

3.5.55

1 year ago

3.5.54

1 year ago

3.5.53

1 year ago

3.5.52

1 year ago

3.4.52

1 year ago

3.4.51

1 year ago

3.4.50

1 year ago

3.4.49

1 year ago

3.4.48

1 year ago

3.4.47

1 year ago

3.4.46

1 year ago

3.4.45

1 year ago

3.4.44

1 year ago

3.4.43

1 year ago

3.4.42

1 year ago

3.3.42

1 year ago

2.3.42

1 year ago

2.3.41

1 year ago

2.3.40

1 year ago

2.2.40

1 year ago

2.2.39

1 year ago

1.2.39

1 year ago

1.1.39

1 year ago

1.1.38

1 year ago

1.1.37

1 year ago

1.1.36

1 year ago

1.1.35

1 year ago

1.1.34

1 year ago

1.1.33

1 year ago

1.1.32

1 year ago

1.1.31

1 year ago

1.1.30

1 year ago

1.1.29

1 year ago

1.1.28

1 year ago

1.1.27

1 year ago

1.1.26

1 year ago

1.1.25

1 year ago

1.0.25

1 year ago

1.0.24

1 year ago

1.0.23

1 year ago

1.0.22

1 year ago

1.0.21

1 year ago

1.0.20

1 year ago

1.0.19

1 year ago

1.0.18

1 year ago

1.0.17

1 year ago

1.0.16

1 year ago

1.0.15

1 year ago

1.0.14

1 year ago

1.0.13

1 year ago

1.0.12

1 year ago

1.0.11

1 year ago

1.0.10

1 year ago

1.0.9

1 year ago

1.0.8

1 year ago

1.0.7

1 year ago

1.0.6

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago