1.0.0 • Published 1 year ago
@diotobtea/laborum-hic v1.0.0
@diotobtea/laborum-hic 
Get the byteOffset
out of a DataView, robustly.
This will work in node <= 0.10 and < 0.11.4, where there's no prototype accessor, only a nonconfigurable own property.
It will also work in modern engines where DataView.prototype.byteOffset
has been deleted after this module has loaded.
Example
const dataViewByteOffset = require('@diotobtea/laborum-hic');
const assert = require('assert');
const ab = new ArrayBuffer(42);
const dv = new DataView(ab, 2);
assert.equal(dataViewByteOffset(dv), 2);
Tests
Simply clone the repo, npm install
, and run npm test
redirectWebSocketgetterECMAScript 6collection.es6javascriptsymlinkseventsECMAScript 2019jsonsearchexecuteECMAScript 2018streamwaapiairbnbreadablefast-deep-copyclass-validatorsnsisglobalsrdsES8IteratorES2021negative zeroidURLwalkinggraphqlfast-clonees2016atomflat@@toStringTagtc39ES2022ArrayBufferArray.prototype.containsinternal slot3dfastintrinsicjapanesepreprocessorutilsetterenvcloneglobalgroupByenumerableonce.envworkspace:*emrapolloanimationerrortimeastqueueentriesdebugwaitasciichromeStreamnopelook-upsymbollrueast-asian-widthmomentMicrosoftimportexportebsWeakMapArrayBuffer#slicelockfilequotepropswfes5readasyncjasminehandlercolorkey parterminalavahttpInt16ArraytelephoneenvironmentsAsyncIteratorpinofprulesservercacheassignwhichuuidhigher-ordergetes2017ArrayTypedArraydefinegdprRFC-6455extrareduxtypeerrordatebyterestcloudformationhooksrobustfolderowneverynodefile cachetddoptimizerautoprefixerfigletqsprivatematchSetreact animation[[Prototype]]proxyemitECMAScript 2022hookformpropertyvarsfullwidthstringcallboundjoixhrtslibPromisedataViewtermtrimredux-toolkitglacieridleidentifierswgetshebangtypedarrayquerystringreuserecursivedeterministicjsprotodefinePropertyhelpervalidutilitiesObjectglobtrimRightECMAScript 5form-validationformathasOwnPropertyautoscalingcore-jstypeofES2016protobufES6elbUint16ArrayES2015source mapchecktrimStart_.extendregexpl10narraysnodejspipekeysregular-expressionhas-ownthreeapiendereventDispatcherec2arraybufferpositiveFloat32ArraytoReversedroutingregexclientcssdayjses8inputwritableinstallponyfilltouchperformancemapreduceyamlfunctionsArray.prototype.includeslibphonenumberWeakSetio-tsajvforEachbrowserslistupzeroprotocol-bufferslanguageconfigurablequeueMicrotaskkarmafnmatchstringifierreadablestreamaccessorUint32ArrayhashrmdirdynamodbReflect.getPrototypeOfsinatrahttpsdropremoveArray.prototype.findLastwhatwgsharedtoolsdependency managerObject.fromEntriesmruspeedreactbuffersspawnRxJSstreamsperformanta11yreducerjshintsuperagentshamexecwalkasteriskses7full-widthreact-hooksframeworkmockingpushMappuredirRegExp#flagsassertsicuansifindLastIndextyped arrayschemeinternaldescriptorsTypeBoxcomputed-typesdatatesterinspectString.prototype.trimistanbulbufferbusyfastcopyreact-hook-formoutputbannerendpointi18n256polyfilltostringtagdomrequirewebschemapromiseaws$.extendjson cachefunctionalsettingsdeepclonetypesafesomeboundYAMLtoArrayprogressbundlingaccessibilityfunction.lengthconcatuser-streamssymbolsxmltransportES2017ES2023Function.prototype.nameES2018simple cacherequestregular expressionmatchescloudsearchUnderscoremapfast-copyflagcolumnfastifycompilercurlwidthES2019callArrayBuffer.prototype.slicestylingcall-bindlocaltypedmanipulationEStransformvalidationjsdomconfigxtermbeanstalktraversetypesafecall-boundinstallerBigUint64Arraypropertiesdirectoryeslint-pluginobjectgetintrinsicbyteLengthsortedmergeequalminimalstylenpmroutenumberdeep-copyObservablebddcircularback-endtoolkitcolourreact-testing-libraryshimwriteCSSStyleDeclarationmockes-shim APIweaksetlengthcolorslintlocationtsiconvstyleguideflagsECMAScript 2021typanioninbinprettytextutilsstripES2020testdeep-cloneprototypesetImmediaterestfulInt8ArrayyupgetoptprefixconcatMapignorechannelieshellpackagescensorinstrumentationtrimEndObject.getPrototypeOffastclonetapcharactertypescriptfetchstringifyhases-shimscolumnsdataviewmobileruntimedependenciesgetPrototypeOfwarningjQueryArray.prototype.flatMapappStyleSheettacitES5stablecss-in-jsramdaes-abstractloadingfilterweakmapequalitylogelectronCSSchromiumphonergbgesturescreatemulti-packageloadbalancinggetOwnPropertyDescriptorkey valuepackagemodulesObject.entriesInt32ArraycharsetassertconsolenpmignoreinvariantECMAScript 2020iteratecommand-lineargspluginmovefpssuperstructfantasy-landmanagerRegExp.prototype.flagsdom-testing-libraryregular expressionsserializationslotargvpicomatchsesdebuggerStreamsefficienttrimLeftscheme-validationserializercharactersregularguidObservablesparseres6stylesindicatorsameValueZeroRxttyargumentclassnamesslicepackage.jsonexecfileECMAScript 2023helperssyntaxerrormkdirdeepcopypnpm9Array.prototype.filtermkdirsviewcjkeventEmitterbyteOffsetquerypostcss-pluginfile systemsidejsdiffpostcssfind-uptapeconvertforkzodcallbindvpcreducereal-timearraymetadataoptimistimportreversedlookenvironmentcryptotestinggenericsunicodeincludesiamshrinkwrapelasticacheimmutabledescriptionchildvalueskoreanUint8Arrayservice-0feedmakeprunenegativecode pointsrmresolveObject.definePropertyiteratorbindloggingfullparentsstoragegatewayJSON-SchemaES7hasOwndiffObject.ischaiReactiveXexpressionamazonESnextsyntaxcodesprocessstructuredCloneWebSocketsinferenceposeparsecloudwatchobjfront-endrm -frmochaECMAScript 2016findupwaftoobjectreverseextend__proto__espreefilelistenersURLSearchParamsrouterspinnerframerString.prototype.matchAllObject.keysutilityclasseshtmlgroupformrfc4122keyecmascriptArray.prototype.flatpyyamlsortspringclassnametakereact posespinnersjsxObject.assignfindLastfsworkflowECMAScript 7cloudfrontTypeScriptescapeformsstartersetdotenvlasttranspilerrapidroute53s3Float64Arraypackage managerloggercallbackECMAScript 2015parentObject.values.gitignoretoStringTaggitignorepoint-freedeleteformattingrssoffsetsqsdragvalueassertionserializefrompopmotioncurriedhardlinksflattenworkeromites2015private datamodulezxbinariesdescriptorrangeerrorcontainseslintnameSymbol.toStringTagmatchAllECMAScript 3typesstyled-componentsesurlBigInt64Arraycopyvest0ECMAScript 2017fast-deep-clonenativepatchES3compareredactarktypeflatMapconsumecommandtoSortedutil.inspecteslintconfigbinaryvalidatecommandersubprocesslinkfindexpresscoresimpledbReactiveExtensionsestreeimmerPushclipatheffect-tsuninstalldeepnamescoveragecollectionchinesesharedarraybufferArray.prototype.flattenfunctionJSONrandom
@diotobtea/a-necessitatibus-assumenda-nam@diotobtea/alias-praesentium-alias-nobis@diotobtea/aut-beatae-molestiae-ipsum@diotobtea/beatae-eligendi-ratione-suscipit@diotobtea/consequuntur-porro-incidunt-nobis@diotobtea/corrupti-quos-neque-dolores@diotobtea/dicta-quas-soluta-placeat@diotobtea/earum-eaque-nemo-ad@diotobtea/eius-explicabo-delectus-voluptatem@diotobtea/enim-aspernatur-inventore-autem@diotobtea/eveniet-eveniet-dolorum-quaerat@diotobtea/explicabo-iste-labore-assumenda@diotobtea/modi-quibusdam-vitae-mollitia@diotobtea/occaecati-qui-commodi-ea@diotobtea/pariatur-vero-nostrum-dignissimos@diotobtea/quaerat-optio-qui-totam@diotobtea/rem-velit-error-in@diotobtea/repellendus-repellat-error-blanditiis@diotobtea/repellendus-veniam-distinctio-nostrum@diotobtea/reprehenderit-alias-cum-consectetur@diotobtea/repudiandae-atque-non-aspernatur@diotobtea/rerum-possimus-quo-ipsum@diotobtea/tempora-vitae-dolorem-molestias@diotobtea/voluptate-enim-excepturi-distinctio@diotobtea/voluptatem-officia-veniam@diotobtea/voluptatibus-ipsum-facere-rerum@diotobtea/voluptatibus-numquam-ratione-consequatur
1.0.0
1 year ago