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

1 year ago

3.9.55

1 year ago

3.8.54

1 year ago

3.8.55

1 year ago

3.8.52

1 year ago

3.8.53

1 year ago

3.8.51

1 year ago

3.8.49

1 year ago

3.8.47

1 year ago

3.8.48

1 year ago

3.8.50

1 year ago

3.7.37

1 year ago

3.7.38

1 year ago

3.8.45

1 year ago

3.8.46

1 year ago

3.8.44

1 year ago

3.7.39

1 year ago

2.2.17

1 year ago

2.7.29

1 year ago

2.2.18

1 year ago

2.7.28

1 year ago

2.2.15

1 year ago

2.7.27

1 year ago

2.2.16

1 year ago

2.3.20

1 year ago

2.7.26

1 year ago

3.7.44

1 year ago

3.7.42

1 year ago

3.7.43

1 year ago

2.2.19

1 year ago

2.6.26

1 year ago

3.7.40

1 year ago

2.7.33

1 year ago

2.2.20

1 year ago

3.7.41

1 year ago

2.7.32

1 year ago

2.7.31

1 year ago

2.6.24

1 year ago

2.7.30

1 year ago

2.6.25

1 year ago

2.7.37

1 year ago

2.7.36

1 year ago

2.7.35

1 year ago

2.7.34

1 year ago

2.5.21

1 year ago

2.5.22

1 year ago

2.5.23

1 year ago

2.5.24

1 year ago

2.4.21

1 year ago

2.4.20

1 year ago

2.2.14

1 year ago

2.1.14

1 year ago

2.0.13

1 year ago

2.1.13

1 year ago

2.0.12

1 year ago

2.0.11

1 year ago

2.0.9

1 year ago

2.0.10

1 year ago

2.0.8

1 year ago

2.0.7

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