4.12.66 • Published 1 year ago

@hishprorg/earum-consectetur v4.12.66

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@hishprorg/earum-consectetur 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/earum-consectetur

Usage/Examples

var groupBy = require('@hishprorg/earum-consectetur');
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/earum-consectetur');
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/earum-consectetur');
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

fastzxmergees8transpilestatecryptregexclassnamedeepclonedeep-clonewindowReactiveXarrayswaitsignedcontainsReflect.getPrototypeOflastfullcloudfrontparserprotocol-bufferstyped arrayrobustbundlerStreamsUint8ClampedArrayhooksdataViewtermECMAScript 2015dependenciesPromisees2018linuxcolorsclientsetImmediatekoreanUint8Arrayes2016locationdefineio-tstddUint32Arrayopenssles-shimssafeFloat64Arraypackagessortgetvariablescommandbeanstalkfast-clonemapreducestoragegatewayreadescapetoStringTagJSONArray.prototype.flatbcryptvalidlessstatelessefficientcjkcollection.es6coerciblepureflagsURLSearchParamssymboljsxdiffjQuerySetchinesetraversefindLastIndexObject.fromEntriesuploadlibphonenumberfpinpropertyexpressreplayes6ownsameValueZeroexecutewritablecomparespeedmovesqsredirectdatalanguagereact-hooksacornramdadataviewtypeerrorinternal slotreduceinvariantstructuredClonejsdomjapaneseESnextdescriptorsuperstructFloat32ArraymacosECMAScript 7-0argumentbindfixed-widthdeterministicflagastprivatefantasy-landvariables in cssdragreadablestreamerror-handling[[Prototype]]metadataansifastify.gitignoresetterpinoformformatrequestsetlogRegExp#flagssharedperformantcloudformationtestreact-hook-formvestclassesbinarysideamazonstringifyobjecttslibsymlinkfiglet0toolkitinternalfunctionfilterchildasciireactisString.prototype.trimthreeregexpInt8Arraycallboundfile systemtc39createstyleguidecheckassertionextraES6postcssECMAScript 5ES2015sequenceECMAScript 2022lesscssArray.prototype.includeschromelocaldeletejscurlfilestyled-componentsObject.getPrototypeOfArrayBuffermkdirEShandlerspersistentkeysgestureshandlerregular-expressionworkspace:*point-freeesunicodegetintrinsicReactiveExtensionsstablecssidentifiersspinnerweakmaptrimRightautoprefixerpathpostcss-pluginasyncsespackage managerindicatorpnpm9nodejslengthPushmulti-packageremovetrimEndl10nslotsyntaxerrorglobalhttpsviewscheme-validationbufferArrayBuffer#slicecalljson-schema-validationasterisksinputroutenegative zeromixinsec2offsetstylesheetgradients css3characterencryptioncensorprivate datafunctionstouchSymbol.toStringTagreducerprettyvpcmanagerrandomstringjson-schemapreserve-symlinksagentes2017WeakSetgradients cssforkvaluecompile lesstelephoneawsgraphqltypanionSymbolglobal objectsymlinksflatMapObjectidlenested css
4.12.66

1 year ago

4.12.65

1 year ago

4.12.64

1 year ago

4.12.63

1 year ago

4.12.62

1 year ago

4.12.61

1 year ago

4.12.60

1 year ago

4.12.59

1 year ago

4.12.58

1 year ago

4.12.57

1 year ago

4.11.57

1 year ago

4.11.56

1 year ago

4.11.55

1 year ago

4.11.54

1 year ago

4.11.53

1 year ago

4.11.52

1 year ago

4.11.51

1 year ago

4.11.50

1 year ago

4.10.50

1 year ago

4.10.49

1 year ago

4.10.48

2 years ago

4.10.47

2 years ago

4.10.46

2 years ago

4.10.45

2 years ago

4.10.44

2 years ago

4.10.43

2 years ago

4.10.42

2 years ago

4.10.41

2 years ago

4.10.40

2 years ago

4.10.39

2 years ago

4.9.39

2 years ago

3.9.39

2 years ago

3.9.38

2 years ago

3.8.38

2 years ago

3.8.37

2 years ago

3.7.37

2 years ago

3.7.36

2 years ago

3.6.36

2 years ago

3.5.36

2 years ago

3.5.35

2 years ago

3.5.34

2 years ago

3.5.33

2 years ago

3.5.32

2 years ago

3.5.31

2 years ago

3.5.30

2 years ago

3.5.29

2 years ago

3.5.28

2 years ago

3.5.27

2 years ago

3.5.26

2 years ago

3.5.25

2 years ago

3.5.24

2 years ago

3.5.23

2 years ago

3.5.22

2 years ago

3.5.21

2 years ago

3.5.20

2 years ago

3.4.20

2 years ago

3.4.19

2 years ago

3.4.18

2 years ago

2.4.18

2 years ago

2.3.18

2 years ago

2.3.17

2 years ago

2.3.16

2 years ago

2.3.15

2 years ago

2.3.14

2 years ago

2.3.13

2 years ago

2.3.12

2 years ago

2.3.11

2 years ago

2.3.10

2 years ago

2.3.9

2 years ago

2.3.8

2 years ago

1.3.8

2 years ago

1.3.7

2 years ago

1.3.6

2 years ago

1.2.6

2 years ago

1.1.6

2 years ago

1.1.5

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago