1.2.1 • Published 11 days ago

@libtommy2024/suscipit-sapiente-repudiandae-culpa v1.2.1

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

@libtommy2024/suscipit-sapiente-repudiandae-culpa Version Badge

github actions coverage License Downloads

npm badge

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

Example

var assert = require('assert');
var isArrayBuffer = require('@libtommy2024/suscipit-sapiente-repudiandae-culpa');

assert(!isArrayBuffer(function () {}));
assert(!isArrayBuffer(null));
assert(!isArrayBuffer(function* () { yield 42; return Infinity; });
assert(!isArrayBuffer(Symbol('foo')));
assert(!isArrayBuffer(1n));
assert(!isArrayBuffer(Object(1n)));

assert(!isArrayBuffer(new Set()));
assert(!isArrayBuffer(new WeakSet()));
assert(!isArrayBuffer(new Map()));
assert(!isArrayBuffer(new WeakMap()));
assert(!isArrayBuffer(new WeakRef({})));
assert(!isArrayBuffer(new FinalizationRegistry(() => {})));
assert(!isArrayBuffer(new SharedArrayBuffer()));

assert(isArrayBuffer(new ArrayBuffer()));

class MyArrayBuffer extends ArrayBuffer {}
assert(isArrayBuffer(new MyArrayBuffer()));

Tests

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

package managerconcurrencysomeECMAScript 2018queueMicrotaskrgbgenericsdirUint8ClampedArrayArray.prototype.findLastIndexbufferparentfunctionstapuninstalldotenvWebSocketsrangeerrorECMAScript 6Int8Arrayes-shimsassertionurltypedarraygetOwnPropertyDescriptoruser-streamsauthenticationtrimRightansimergemkdirsmacosserializeelectronpushframeworkRxJSmocharedux-toolkitregexpchanneleventEmitterlistenersassertsstylesUint8ArraysyntaxquerycircularweaksetcompilerPromisepnpm9styleguideRegExp#flagsmatchesapifull-widthmodulereact-testing-libraryES6flagfast-deep-copydependenciesratelimitkeysRxtypessigintoptimistTypedArraypathgroupentriesprivate dataStreamajvaccessorfspruneECMAScript 3BigInt64ArraypipermnamesmimetypesMicrosoftECMAScript 2021regular expressionvisualslotargscolorcommand-lineloggercallboundmakeform-validationcheckAsyncIteratores8queueArrayBufferJSON-Schematouch@@toStringTagcss lessexit-codeshamrm -frbyteLengthenvtypesafenumberinterruptsshrinkwrapWebSocketreducerconcatlibphonenumberes-abstractavacompile lessrandomTypeBoxprettymobile3dnameworkspace:*dropdefinePropertycommandersyntaxerrorvalidationastnopeReflect.getPrototypeOfreact-hookstypeerrorString.prototype.trimerror-handlingescapefunctionalcryptoECMAScript 2023optionparsetyped arrayramdaECMAScript 2020objfast-clonetoolskoreanObservablesArray.prototype.findLastbytefast-copylastnegativeschemedragguidruntime__proto__karmasafeSymbol.toStringTaglesspreprocessorrm -rfpropless cssWeakMapspinnersmime-dbjsdiffvalidargumentbcryptmatchassertvalidatecallbindtslibjasminepyyamlttyreadablecollectionregexidawesomesaucefunctionreduxcliuptoobjectdefineES3polyfillslicetranspilenativeeditordataviewutilitybuffersbundlertrimmatchAllhttpopenestreetranspilerjson-schema-validatorbootstrap lessiejsonpathflattenarraybufferArray.prototype.flatMapfindLastIndexawaitsymlinksES7phoneES5airbnbio-tsgetoptextendmomentspecreactESInt32ArrayArray.prototype.filterstyleprocessrequestchildtrimEndjson-schema-validationObservableES2022clonedataViewstringifyoutputhookformclassesxhrdeletecharactersexpressbrowserlistArray.prototype.includesperformanceconfigurablefindupes2018throatprotocol-buffersargparseFloat32Arrayeveryresolvegdprfigletcss-in-jsmapscheme-validationsetterObjectBigUint64ArraytrimLeftwatchyuplogpoint-freeStreamsonceinspectjwtincludesdependency managercjkpackage.jsondom-testing-libraryshellcorssymbolsfast-deep-clonexsslockfilecurried-0typedpasswordtoArraybabelformattingloggingstyled-componentsinternalhttpsloadingsignalbddfile systemsharedESnextUnderscoreartbanneres2016fastcacheObject.keyscallreact poselinuxtimedebugdefaultopenerES2018asciiomitinputtaketrimStartarraydateharmonytostringtagexitwordwraplaunchwhatwgECMAScript 5eslintconfigWeakSetInt16Array_.extendqssuperagentsorttasknodeString.prototype.matchAllunicodespinnersymlinkcall-bindjscomparecolumnsinvariant[[Prototype]]babel-coreprotoES2023postcssa11yArray.prototype.containscrypttoStringTaglintemojiimmertoolkites7bundlingconstcollection.es6CSStapeinstalloptimizerletexecutablefindbusymodulesauthindicatordayjsreal-timermdirArrayObject.definePropertymkdirstreams2irqassign256testershimpostcss-plugintoSortedtraversebluebirdlooklimitfpObject.islanguageshebangboundRFC-6455ReactiveExtensionsFunction.prototype.nameformatcss nestingnegative zeroprototypeECMAScript 7promisescallbackconsoletypanionwritableformbatchclientequalUint32ArraycolorssanitizationSymboldirectoryurlsdatastructureparentsasyncstylesheetredactcoreFloat64ArrayfastcloneIteratorMapinferenceerrorpluginutilsArray.prototype.flatjapanesemulti-packagehigher-ordermiddlewarees2017streamsES2017performantlinewrapzerofilefixed-widthsequencefind-upefficientchromedeterministicsameValueZerospeedfullObject.getPrototypeOfecmascriptcensorwidthjsxcurlrapidcharacterinstallerforEachCSSStyleDeclarationencryptionpropertiesdommake dirjoisearchsetPrototypeOfspawnfindLastgetvariableslengthajaxcolumnclass-validatorhookseast-asian-widthchaicreatesharedarraybufferequalityformspureminimaldeep-cloneutillruObject.assignprefixRegExp.prototype.flags
1.2.0

11 days ago

1.2.1

11 days ago

1.0.0

1 month ago