4.12.66 • Published 11 months ago

@hishprorg/earum-consectetur v4.12.66

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months 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

11 months ago

4.12.65

11 months ago

4.12.64

11 months ago

4.12.63

11 months ago

4.12.62

11 months ago

4.12.61

11 months ago

4.12.60

11 months ago

4.12.59

11 months ago

4.12.58

11 months ago

4.12.57

11 months ago

4.11.57

11 months ago

4.11.56

11 months ago

4.11.55

11 months ago

4.11.54

11 months ago

4.11.53

11 months ago

4.11.52

11 months ago

4.11.51

11 months ago

4.11.50

11 months ago

4.10.50

11 months ago

4.10.49

11 months ago

4.10.48

11 months ago

4.10.47

11 months ago

4.10.46

12 months ago

4.10.45

12 months ago

4.10.44

12 months ago

4.10.43

12 months ago

4.10.42

12 months ago

4.10.41

12 months ago

4.10.40

12 months ago

4.10.39

12 months ago

4.9.39

12 months ago

3.9.39

12 months ago

3.9.38

12 months ago

3.8.38

12 months ago

3.8.37

12 months ago

3.7.37

12 months ago

3.7.36

12 months ago

3.6.36

12 months ago

3.5.36

12 months ago

3.5.35

12 months ago

3.5.34

12 months ago

3.5.33

12 months ago

3.5.32

1 year ago

3.5.31

1 year ago

3.5.30

1 year ago

3.5.29

1 year ago

3.5.28

1 year ago

3.5.27

1 year ago

3.5.26

1 year ago

3.5.25

1 year ago

3.5.24

1 year ago

3.5.23

1 year ago

3.5.22

1 year ago

3.5.21

1 year ago

3.5.20

1 year ago

3.4.20

1 year ago

3.4.19

1 year ago

3.4.18

1 year ago

2.4.18

1 year ago

2.3.18

1 year ago

2.3.17

1 year ago

2.3.16

1 year ago

2.3.15

1 year ago

2.3.14

1 year ago

2.3.13

1 year ago

2.3.12

1 year ago

2.3.11

1 year ago

2.3.10

1 year ago

2.3.9

1 year ago

2.3.8

1 year ago

1.3.8

1 year ago

1.3.7

1 year ago

1.3.6

1 year ago

1.2.6

1 year ago

1.1.6

1 year ago

1.1.5

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago