1.0.0 • Published 12 days ago

@landmineaknpm/libero-nesciunt-reprehenderit v1.0.0

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

@landmineaknpm/libero-nesciunt-reprehenderit Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

An ES5 mostly-spec-compliant Object.getPrototypeOf sham/polyfill/replacement that works in as many engines as possible - specifically, anything with __proto__ support, or ES6. Built-in types will also work correctly in older engines.

This package implements the es-shim API interface. It works in an ES3-supported environment and complies with the spec.

Example

var getPrototypeOf = require('@landmineaknpm/libero-nesciunt-reprehenderit');
var assert = require('assert');

assert.equal(getPrototypeOf(true), Boolean.prototype);
assert.equal(getPrototypeOf(42), Number.prototype);
assert.equal(getPrototypeOf(''), String.prototype);
assert.equal(getPrototypeOf(/a/g), RegExp.prototype);
assert.equal(getPrototypeOf(new Date()), Date.prototype);
assert.equal(getPrototypeOf(function () {}), Function.prototype);
assert.equal(getPrototypeOf([]), Array.prototype);
assert.equal(getPrototypeOf({}), Object.prototype);
var getPrototypeOf = require('@landmineaknpm/libero-nesciunt-reprehenderit');
var assert = require('assert');
/* when Object.getPrototypeOf is not present */
delete Object.getPrototypeOf;
var shimmed = getPrototypeOf.shim();
assert.equal(shimmed, getPrototypeOf.getPolyfill());

assert.equal(Object.getPrototypeOf(true), Boolean.prototype);
assert.equal(Object.getPrototypeOf(42), Number.prototype);
assert.equal(Object.getPrototypeOf(''), String.prototype);
assert.equal(Object.getPrototypeOf(/a/g), RegExp.prototype);
assert.equal(Object.getPrototypeOf(new Date()), Date.prototype);
assert.equal(Object.getPrototypeOf(function () {}), Function.prototype);
assert.equal(Object.getPrototypeOf([]), Array.prototype);
assert.equal(Object.getPrototypeOf({}), Object.prototype);
var getPrototypeOf = require('@landmineaknpm/libero-nesciunt-reprehenderit');
var assert = require('assert');
/* when Object.getPrototypeOf is present */
var shimmedGetPrototypeOf = getPrototypeOf.shim();
assert.equal(shimmedGetPrototypeOf, Object.getPrototypeOf);
assert.equal(Object.getPrototypeOf([]), Array.prototype);

Tests

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

callbackscheme[[Prototype]]childFloat64Arraytapemkdirp@@toStringTagmodulesindicatortaskoptionvalidationcryptojQuerylaunchparsetypenodeassertsyntaxerrorArray.prototype.containsiteratemonorepoObject.entriesfilefastcolumnexpresssetImmediategroupthreemiddlewarerm -frwaapibrowserslistcollection.es6dom-testing-libraryES5formattingnopecss lessvisualgetPrototypeOfmake dirArray.prototype.flatvalidatorarrayforEachremoveassertses6numbersignalsES2016spinnersutilsarraybufferierobustWebSocketasciiinferenceguidwhatwggenericscompilerdirectorywidthcall-boundpackageES7findreact-hooksfind-upscheme-validationgetoptsigintECMAScript 2015extravestreadenvironmentfullreduceFloat32Arraythrottleeast-asian-widthCSSbyteobjectserializationmerge6to5gradients css3deterministicmap_.extendlimitedquerystringextendjson-schema-validatorprocessxdg-openES2018urlsisConcatSpreadableSymbolsearcharraysfast-deep-copyuninstallcall-bindkoreanconfigurableclientmixinsasyncloadingeverytsmulti-packagenameInt32ArrayES2022ArraydroptrimRightArray.prototype.findLastIndexdirinterruptsrequestECMAScript 2016writeconcatbrowserlistfigletdependenciescircularstreamdebugzero-0argsstyleguideinspectserializeRegExp.prototype.flagstypanionauthenticationlesscsswatchFilebreaknamessignalsettertslibtc39domclassesObject.keysmimetypesspinnerbusyjoijsruntimeeslintconfiganimationgetintrinsiciterationwordwraptypedarraysio-tsexecsetPrototypeOfrangeerrorqueueECMAScript 2019configflattenupnpmemitES2017preprocessorstarter$.extendserializerbundlingreadablestreamtypedpackagesjsxeventDispatcherpolyfillcharacterlookcssphonereduxtoArraytraverseutilitiesfunctionmomenttoStringTagextensionparentspipecore-jsclassnamestypedarraywatcherpackage.json__proto__callboundpropertiesansiStyleSheetTypedArrayless cssistypescriptJSON-Schemaexit-codeUint16ArrayESjson-schema-validationfpurldeep-cloneformatArray.prototype.filterloggerlengthauthdataViewworkspace:*purejsdomhashxhrcolorYAMLhooksRxES2015babel-corebyteOffsetomitnodejstakeframeworktranspileless compilerjavascripttelephonelesscurriedenvbundlerenumerableURLtddObservablevalidfastcopycommanderprotofolderpersistentes5streams2columnsopenerinputmatcheslibphonenumbershebangponyfillcensorfantasy-landbcryptgroupByfetchperformantapigetOwnPropertyDescriptorsideexecutableflatwebsiteoutputbanneres-abstractfunctionalavadateflatMapArray.prototype.findLastdefinePropertycheckMicrosoftStreamstyped arrayjsonlook-upBigUint64Arraywalkingestreeeslintdependency managerdatabrowserajvECMAScript 2023performanceinternalsanitizationlintdotenvhandlerspyyamlwarningcoerciblebyteLengthttyES2019enderqueueMicrotaskobjuser-streamstranspilerpicomatchJSONincludesslotES2023tacitsharedarraybuffermoveuuidcolorstapcommand-linehigher-orderclonepassworddiffWeakMapUint32ArrayfscompareES3RxJStostringtagjasminewritablestyleajaxsymlinkscommandweaksetReactiveExtensionsECMAScript 2018mimefromgraphqlschemawebfindLastharmonychinesesuperagentfast-copyUint8ArrayshamtestmetadataECMAScript 7es-shimses2017formprivate dataduplexdeepcloneqsequalimmutableencryptionless mixinsECMAScript 3invariantreducerreact-hook-formframerdeep-copytimeArray.prototype.includeshookformwaitpoint-freeargvspringdeletetesterformsmkdirsinternal slotES2021parserstylesheetECMAScript 2022class-validatorstructuredCloneinstallopenimmerReflect.getPrototypeOfcryptassignrate0Uint8ClampedArrayes7ArrayBufferfixed-widthdebuggerterminalshrinkwrapdefaultdayjsstreamsmatchAllsameValueZeropnpm9japaneseIteratorless.jselectronpositivecachestartesArrayBuffer.prototype.slicelanguagechaiweakmapresolverm -rfgetterURLSearchParamsfull-widthtoSortedprunedragnegative zeroratelimitairbnberrorlinuxredux-toolkitwordbreaksetdatastructureinstallersuperstructvaluesrequireawaitjsonschemawalkgesturesrandomsymbolsmruawesomesaucefseventstrimStartequalityArray.prototype.flattenshelltoolsform-validationtouchSymbol.toStringTagcurlreal-timechromeSetWebSocketsprotocol-bufferschromiumtrimappbluebirdObject.isvalidatecodespromisestatusaccessorimportregularjson-schemaparentkarmaposetypeerrorworkerMapcallbindWeakSetboundmobilepreserve-symlinksprotobufassertionthroathttpshelpersshimreact poseECMAScript 5jesteventssymlinkECMAScript 6openslogreact-testing-librarytypesECMAScript 2017ArrayBuffer#sliceString.prototype.matchAllUnderscorexssplugina11yvariablesiteratortrimEndeslintpluginjsdiffStreamtestingCSSStyleDeclarationpushastnested cssstylesAsyncIteratorspeedESnextdescriptorlinewrapregexprivatetermdefineconcurrencybindBigInt64ArraysymbolfindLastIndexmakemodulesliceerror-handlingconcatMapes2015
1.0.0

12 days ago