3.6.73 • Published 2 years ago

@hishprorg/quia-reprehenderit v3.6.73

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

@hishprorg/quia-reprehenderit Version Badge

github actions coverage License Downloads

npm badge

An ESnext spec-compliant Object.groupBy shim/polyfill/replacement that works as far down as ES3.

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

Getting started

npm install --save @hishprorg/quia-reprehenderit

Usage/Examples

var groupBy = require('@hishprorg/quia-reprehenderit');
var assert = require('assert');

var arr = [0, 1, 2, 3, 4, 5];
var parity = function (x) { return x % 2 === 0 ? 'even' : 'odd'; };

var results = groupBy(arr, function (x, i) {
    assert.equal(x, arr[i]);
    return parity(x);
});

assert.deepEqual(results, {
    __proto__: null,
    even: [0, 2, 4],
    odd: [1, 3, 5],
});
var groupBy = require('@hishprorg/quia-reprehenderit');
var assert = require('assert');
/* when Object.groupBy is not present */
delete Object.groupBy;
var shimmed = groupBy.shim();

assert.equal(shimmed, groupBy.getPolyfill());
assert.deepEqual(Object.groupBy(arr, parity), groupBy(arr, parity));
var groupBy = require('@hishprorg/quia-reprehenderit');
var assert = require('assert');
/* when Array#group is present */
var shimmed = groupBy.shim();

assert.equal(shimmed, Object.groupBy);
assert.deepEqual(Object.groupBy(arr, parity), groupBy(arr, parity));

Tests

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

forEachglobal objectvalidateflattenlocationtranspiler_.extendbrowserslistES8everyautoprefixerremovedropReactiveExtensionslibphonenumberInt32ArraysharedarraybufferWeakMaptypedbabelloggingbrowsergetoptpropfast-copyfastcopyassertstyled-componentsextrasyntaxcss-in-jssimpledbObject.getPrototypeOfclassnamextermArrayjwtforkjsonschemaArray.prototype.findLastlinuxpopmotionfindLastdependenciesmatchcommandernodeloggradients css3route53importexportpathendpointpinohelperES2023Pushexpressmockletruntimefunctionfront-endwalkprotopicomatchloading3dinternal slotresolveapolloeventEmitterxhrsetImmediatesortedtyped arraycreateecmascriptagentschemaenumerabledragInt16ArrayprivatefullnodejsTypeScriptnamesfigletprocessbcryptvalidatordeleteobjhandlerlesscssconcatchinesebannerbabel-coredomformatoncemockingESnextbinariesserializationquotebinarychildvalueimmermkdirstoobjectinspectWebSocketfluxauthPromiseES6indicatorreact-hookscensorreadableworkflowback-endclassnamesjoibinvisualbddUint8ArrayES3symbolsestrimLeftpostcss-plugines7equalregularURLSearchParamssignedserializerspeedutilitiesmixinscloudsearchscheme[[Prototype]]tacitcryptmake dirsameValueZerocoerciblenegativetslibfastcloneJSONes5jstoStringTagObject.entriescryptoasterisksES2015swftypequeryjQueryjshintwarningscheme-validationnumberdataViewarraybufferfastifyECMAScript 2017ECMAScript 2019regular-expressiontestingassertssafecallbackloadbalancingArrayBufferfparraycss nestingECMAScript 2018timelistenersdeep-cloneauthenticationfixed-widthredactviewglobalslotinstallermonorepotranspileanimationansitoArrayboundtypesafeopensslrulespredictablepatchFunction.prototype.nameTypeBoxrdsutilIteratorairbnbpasswordwritablepositivemodulevariablesidentifiersgraphql@@toStringTagqueuetostringtagponyfillSetstreamsTypedArraymomentsetterroutingRFC-6455chaicall-boundfilterdom-testing-libraryes2017call-bindchromiumglobalsstreamArrayBuffer.prototype.slicefrompuresettingsprototypeutil.inspecttypedarraytelephonegetOwnPropertyDescriptorglacierawesomesaucepackage.jsonpreprocessorhandlersfunctionscolumnassigndefinelrues-shimsfindttydescriptiontrimRightsignalsstringifiertouchnamehelpersdeep-copystable.gitignorepnpm9ES2018widthspinnerpropertyString.prototype.trimBigInt64Arraycollectionec2sideuploadhasECMAScriptdeepcopyinferencetrimStart.envdotenvweakmapeast-asian-widthelbRegExp#flagscoreio-tstoolkitprivate datafast-clone$.extendyupStreamsbusycss lessnpmserverjson-schemasequencemobileArray.prototype.flattenjavascriptgroupsigtermform-validationmapreducelengthpropertiesenvcallbindArray.prototype.containsObject.definePropertyclistoragegatewaydynamodbtypescriptcachestructuredCloneReactiveX0validbyteexit-codeemitredux-toolkitdirregexless cssObject.fromEntriesacornbundlershrinkwrapoperating-systemArray.prototype.flatfsES5ArrayBuffer#sliceObject.assignCSSoptionlazyJSON-SchemaefficientmatchAllqueueMicrotasksuperagentignoreprettyuser-streamsvarES2019astECMAScript 6formstestloggerArray.prototype.findLastIndexcertificatesmruvpccsssubprocesssymlinkssyntaxerrorstylesescapeECMAScript 2021offsetcjkshared-0idleautoscalingcloudwatchgitignoreprogressquerystringaccessorreusecallespreecontainscopysesObservablesarktypereact-hook-formsnsrgbdayjsgroupBystatelesschromemacositeraterecursivebootstrap cssUint16ArrayparseES2016ienegative zeroclientgetPrototypeOfprotocol-buffersdeepencryptionStreampromisebeanstalkconfigurablereadbrowserlistlessglobtddbootstrap lesspluginharmonyimmutablecloudfrontserializesomejson-schema-validationpipecompilerexecfilepruneownoutputclassesECMAScript 5gdprpoint-freewhichworkeri18nURLspawnjsdiffECMAScript 7setPrototypeOfhasOwnPropertyinputString.prototype.matchAllstringmodulesgetintrinsicfast-deep-copychannelthreeoptimizerisConcatSpreadablespinnerstypeerrorcolumnstakeweaksetES2020mkdirfindLastIndexl10nequalityfast-deep-clonecomputed-typesrangeerrorstarterfnmatchwaita11yzodsetECMAScript 3eslintjson-schema-validatorfull-widthes-abstractomites6maplockfilestyleguideES2021__proto__polyfillarthardlinksarrayswaapipackage managercloudtrailkeysstylesheetreal-timevalidationeventDispatcherinvariantinternalflatMaptsmkdirpwgetflates8Uint8ClampedArraynopelastcheckajvspecrouteexitshellframerenvironmentexecutees-shim APIphonepreserve-symlinksajaxcharacterreducertrimEndHyBinested cssStyleSheetargsconstfunctionalUnderscoreparserMapdatastructurefile systemnativeiterationpushasyncfetchliveaccessibilitywindowswhatwgcommanddeterministicperformantjestInt8ArraydescriptorsshimWeakSetrandomRxJSSystem.globalclass-validatoreslintconfigtransportreadablestreamcurriedgenericseslintpluginhotObservablecirculartypeofAsyncIteratorcommand-linedependency managersigintzxpyyamlReflect.getPrototypeOfgetterhigher-orderflagMicrosoftcodesreact-testing-libraryprefixcompile lesswritewindowfunction.lengthdescriptorstringifylintshamregexpjapaneseRxformattinghasOwnredirectflagsdataviewBigUint64ArrayECMAScript 2015valuess3proxybundlingassertionramdahashreduceglobalThisurles2016amazonselfjsonless mixinswafjsdomhookformWebSocketsmovediffinterruptsrapidUint32ArraycurlspringasciicolourinstallObject.valueses2018workspace:*bufferrobustsortformreact-componentECMAScript 2023localdirectorystyleelminstatekoreanless.jshttptextvarsbuffersenderposeerrorFloat32Arrayimport
3.6.73

2 years ago

3.6.72

2 years ago

3.6.71

2 years ago

3.6.70

2 years ago

3.6.69

2 years ago

3.6.68

2 years ago

3.6.67

2 years ago

3.6.66

2 years ago

3.6.65

2 years ago

3.6.64

2 years ago

3.5.64

2 years ago

3.5.63

2 years ago

3.5.62

2 years ago

3.5.61

2 years ago

3.5.60

2 years ago

3.5.59

2 years ago

3.5.58

2 years ago

3.5.57

2 years ago

3.5.56

2 years ago

2.5.56

2 years ago

2.4.56

2 years ago

2.4.55

2 years ago

2.4.54

2 years ago

2.4.53

2 years ago

2.3.53

2 years ago

2.3.52

2 years ago

1.3.52

2 years ago

1.3.51

2 years ago

1.3.50

2 years ago

1.3.49

2 years ago

1.3.48

2 years ago

1.2.48

2 years ago

1.2.47

2 years ago

1.2.46

2 years ago

1.2.45

2 years ago

1.2.44

2 years ago

1.2.43

2 years ago

1.2.42

2 years ago

1.2.41

2 years ago

1.2.40

2 years ago

1.2.39

2 years ago

1.2.38

2 years ago

1.2.37

2 years ago

1.2.36

2 years ago

1.2.35

2 years ago

1.2.34

2 years ago

1.2.33

2 years ago

1.2.32

2 years ago

1.2.31

2 years ago

1.2.30

2 years ago

1.2.29

2 years ago

1.2.28

2 years ago

1.2.27

2 years ago

1.2.26

2 years ago

1.2.25

2 years ago

1.2.24

2 years ago

1.2.23

2 years ago

1.2.22

2 years ago

1.2.21

2 years ago

1.2.20

2 years ago

1.2.19

2 years ago

1.2.18

2 years ago

1.2.17

2 years ago

1.2.16

2 years ago

1.2.15

2 years ago

1.2.14

2 years ago

1.1.14

2 years ago

1.1.13

2 years ago

1.1.12

2 years ago

1.1.11

2 years ago

1.1.10

2 years ago

1.1.9

2 years ago

1.1.8

2 years ago

1.1.7

2 years ago

1.1.6

2 years ago

1.1.5

2 years ago

1.1.4

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago