3.9.60 • Published 1 year ago

@zitterorg/doloremque-sed v3.9.60

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@zitterorg/doloremque-sed 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/doloremque-sed');
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

react-testing-libraryES6matcharktypecopychromiumselfeslintpluginlook-upjson-schema-validatortouchconfigparentsUnderscorewindowairbnbpropcolourxtermboundform-validationarttypeerrorfastcopyObservableproxypushtapespeedcliReflect.getPrototypeOfRFC-6455emitmobilesimpledbeveryjsxrssdependenciesdate256libphonenumberES2022querystringes-shim APIcreatesymbolsjsdomArray.prototype.includessetES2021TypedArrayUint8ArraytoReversedpathhttpsiamdefinePropertyefficienthtmlendpointponyfillInt8ArraysomeYAMLappslicecollection.es6envTypeBox__proto__fastifyelasticacheURLshebangpostcss-pluginqueueMicrotasksettingsmrucacherobustpropertyasciis3binSetexecmkdirpjsdifftc39cloudwatchrm -rfprocessBigUint64ArrayshellBigInt64ArrayacornjsonjshintCSSgettranspilertypesafeassertionconfigurableserializationwidthemojisubprocessArray.prototype.filterES7pluginpicomatchconcattypescripttrimbrowserlistnumberpinosuperstructESnexteffect-tscall-boundECMAScript 7expressionperformantsafetrimStartfilter-0functionsramdacloudfrontlocaldataviewagentObject.definePropertycloudtrailregexqswhichdeep-copyReactiveExtensionsclassnamesforEachweaksetmetadatababel-coreisargvoutputregular-expressionprivate dataconstUint8ClampedArraynegative zero3dmergeio-tsdefinevisualpropertiesbufferhelperJSONqueryreduxrm -frtrimEndprivatees-shimsxmlutilsdeletebrowserslistformattingstableautoprefixerStyleSheetzodstyleseventsArrayBuffercomparelastECMAScript 2023buffersmoduleextendamazonlogECMAScript 2017parseES2017clientjestECMAScript 6nativeString.prototype.trimES2023dataflagsfilecsslocationcollectionhasOwnPropertyPushinferencevariablesstylingObject.assignES2016utilitiesflagsharedarraybuffermoduleslengthfastcloneWeakSetdotenvnegativeterminalsymlinksemrcheckfast-copyECMAScript 3functionalclonefunction.lengthdragpatchhas-owngraphqlresolvejsletFunction.prototype.namerecursivetypanioncallboundObservablesObject.fromEntriesaccessorregular expressionWeakMapwgetecmascriptyamlkeycharactersArrayBuffer.prototype.slicefindLastIndexreadablestreampostcssObject.isastarrayfpsjapaneseavaredactcurlfeedgenericsmonorepocontainsfullwidthjQuerykarmacryptoprotobufArray.prototype.containstermSymbol.toStringTagES3ES2015fnmatchieexpressdescriptorsownvaluedataViewpruneisConcatSpreadableconsumeECMAScript 2016nodejsdirreversenamesortomittostringtagminimaleslintconfigglacierglobstyled-componentslockfileTypeScriptworkflowrfc4122fixed-widthrapidutil.inspectspawnconsolevareventDispatcherredux-toolkitcoerciblefind-upshamtypeoffantasy-landmanagerenvironmentspinnercallbackforms.envtoSortedenvironmentsinrestfulautoscalingcommand-linel10nObjectfunctionwritableobjectes8lrujson-schema-validationstructuredClonespringreact posewritewarningMicrosoftkinesistslibeslint-pluginreal-timebinariesFloat32ArraybyteLengthescapechrometelephoneECMAScript 2022entriesignorelanguagechannelcomputed-typesinvariantes2017hashAsyncIteratorURLSearchParamsreadablestyleguidePromisees6ES2019optimistrdspositivedropiteratordynamodbstringidleviewserializerjavascriptfast-deep-copyuninstallIteratorbyteOffsetapiphonenpmignoremapreducefast-clonevarscoreInt32Arraychairgbcoveragerework
3.9.60

1 year ago

3.9.59

1 year ago

3.9.57

1 year ago

3.9.58

1 year ago

3.9.56

2 years ago

3.9.55

2 years ago

3.8.54

2 years ago

3.8.55

2 years ago

3.8.52

2 years ago

3.8.53

2 years ago

3.8.51

2 years ago

3.8.49

2 years ago

3.8.47

2 years ago

3.8.48

2 years ago

3.8.50

2 years ago

3.7.37

2 years ago

3.7.38

2 years ago

3.8.45

2 years ago

3.8.46

2 years ago

3.8.44

2 years ago

3.7.39

2 years ago

2.2.17

2 years ago

2.7.29

2 years ago

2.2.18

2 years ago

2.7.28

2 years ago

2.2.15

2 years ago

2.7.27

2 years ago

2.2.16

2 years ago

2.3.20

2 years ago

2.7.26

2 years ago

3.7.44

2 years ago

3.7.42

2 years ago

3.7.43

2 years ago

2.2.19

2 years ago

2.6.26

2 years ago

3.7.40

2 years ago

2.7.33

2 years ago

2.2.20

2 years ago

3.7.41

2 years ago

2.7.32

2 years ago

2.7.31

2 years ago

2.6.24

2 years ago

2.7.30

2 years ago

2.6.25

2 years ago

2.7.37

2 years ago

2.7.36

2 years ago

2.7.35

2 years ago

2.7.34

2 years ago

2.5.21

2 years ago

2.5.22

2 years ago

2.5.23

2 years ago

2.5.24

2 years ago

2.4.21

2 years ago

2.4.20

2 years ago

2.2.14

2 years ago

2.1.14

2 years ago

2.0.13

2 years ago

2.1.13

2 years ago

2.0.12

2 years ago

2.0.11

2 years ago

2.0.9

2 years ago

2.0.10

2 years ago

2.0.8

2 years ago

2.0.7

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago