3.5.102 • Published 2 years ago

@taktikorg/vitae-a v3.5.102

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

@taktikorg/vitae-a 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 @taktikorg/vitae-a

Usage/Examples

var groupBy = require('@taktikorg/vitae-a');
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('@taktikorg/vitae-a');
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('@taktikorg/vitae-a');
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

call-boundemojisesstarterinternalebsshebangsearchfixed-widthECMAScript 2023WeakMapreduxcharactersawstermexecutepackageshigher-orderlastsharedarraybufferreversedcloudwatchjsutilswfsetImmediateschemevalidatehasOwnPropertyES2016ECMAScript 2019YAMLworkerfullefficientWebSocketarktypedeleteObject.getPrototypeOfMapArraysetponyfillparserES5autoscalingtypedBigUint64ArraycallboundequalityformattinglistenersperformantavaenvMicrosoftprunezerohardlinkspipetranspilepolyfilltrimES2023queryfantasy-landcurriedi18ncolumneventsTypeScriptInt16ArraynegativedynamodbschemainvariantarrayssomejasmineformseslintpushaccessorstylingString.prototype.trimthreeFloat32ArrayproxyfiltertshasOwnobjtrimEndmanagermomentglobalThisimportexportredactbyteOffsetCSSStyleDeclarationdom-testing-libraryeslint-pluginiterateFunction.prototype.namefast-deep-cloneautoprefixeranimationwhichcolourstringreusetypesafeajaxlookisConcatSpreadableutilitiespluginSystem.globalObject.keyses5includesworkflowtostringtagchromequeueObject.fromEntriesroute53intrinsicpnpm9react-testing-libraryio-tsreact-hook-formsource mapramdasliceimmutableenvironmentsassertionatombddpathstyled-componentstypedarraysObjectStreamgetintrinsicdataterminaluuidutilsec2dotenvfindLastIndexcollectionJSONvalue-0installelasticacheWebSocketsdeep-copyECMAScript 6dataviewAsyncIteratorvisualmake diroutputsymbolsdeepclonelanguagepropertiesruntimecssrm -rfclientmochaArrayBuffer#slicetestsubprocessastSetflattendiffkarmaescapecloudformationES2018mkdirsdescriptorfunctionalprocesswafcommanderlinkreactkoreancallbacklocationcopyArray.prototype.filtereast-asian-widthECMAScript 2021equalrapidinstrumentationes2017ES2022shimcoreworkspace:*ArrayBuffer.prototype.slicebundlinghookformcolorspinofeedrulesimmeryuplook-uprmdirmaptrimStartwalkingRegExp.prototype.flagspropsetterECMAScript 2022sidejsxcjkmergeconfigurableshelllogginginputwaitbannertslibnodejsUint8ArrayextraomitassignviewUint8ClampedArraytapFloat64Arrayassertsfast-deep-copyflagscloudfronttraverseharmonyesclasseswriteslotexpressionnativexhrReflect.getPrototypeOfrssconcatsharedaccessibilityqsbyteLengthfses2018global objectwalkparsetypescriptrangeerrorWeakSetfastifyextend6to5propertytimefetchbrowsermodulesspecdateECMAScript 2016kinesistoolsbinhtmlredux-toolkitoptionjQuerytypespicomatch256javascriptrecursivetypeerrorvalidatorelectronstringifierflatMapmulti-packagedescriptorsglobalinbrowserlistrdsgraphqlbindarraygetterUnderscoreclonetoolkitawesomesauceiteratorRxJScreatetransportcolumnskeytranspilerECMAScript 2015trimLefteffect-tsstylesbusyidfastcopyObject.assignlibphonenumberendertddgetJSON-SchemaposehooksreststreamsvarzxrouterEShelpersbuffersmakenegative zeroprototypetc39ES2017descriptionquerystringparentspromiseexeccloudtrailsqses2015stringifypackage.jsonjapanesedraginferencejoi$.extendCSShasdependency managerdependencieswebmatchesInt32Arrayes-abstractfromguidprivateArray.prototype.flattenxtermparentreverseperformanceECMAScript 7computed-typesdayjsrmfull-width_.extendhas-own0optimistes7logoncerandomIteratorclifunction.lengthsetPrototypeOfdataViewendpointlocaljsdomTypeBoxwhatwgfunctionpackagedebuggersortedprotobufcheckart[[Prototype]]censordrop.gitignorespinneryamlstyleserializationcode pointsinspectregular-expressiongenericsfindreact poseconsumeSymbol.toStringTagES8compilerclassnamespeedtoobjectvpcframerinternal slotObject.entriesBigInt64ArraytextArray.prototype.flatspawntoArrayimportselffast-copymruArray.prototype.flatMapstreamsnshashtrimRightreadableforkbabel-corecollection.es6symlinksvariablesagentglobalsuser-streamsECMAScriptgesturesfunctionscolorspringnamesPromisemetadataidleglaciermobilechaidefinees-shim APIES2019formpackage managerprotocol-buffersprettyecmascriptloadbalancingvalidSymbolrequestcalls3getPrototypeOfforEachjson-schema-validationReactiveExtensionscacheinstallerstableapicss-in-jsArray.prototype.includesenvironmentupchinesedomasteriskscore-jsregularfigletdeepvesttelephoneacornredirectStyleSheetwarningsort
3.5.102

2 years ago

3.4.102

2 years ago

3.4.101

2 years ago

3.3.101

2 years ago

3.3.100

2 years ago

3.3.99

2 years ago

3.3.98

2 years ago

3.3.97

2 years ago

3.3.96

2 years ago

3.3.95

2 years ago

3.3.94

2 years ago

3.3.93

2 years ago

3.3.92

2 years ago

3.2.92

2 years ago

3.2.91

2 years ago

3.2.90

2 years ago

3.2.89

2 years ago

3.2.88

2 years ago

3.2.87

2 years ago

3.2.86

2 years ago

3.1.86

2 years ago

3.1.85

2 years ago

3.1.84

2 years ago

3.1.83

2 years ago

3.1.82

2 years ago

3.1.81

2 years ago

3.1.80

2 years ago

3.1.79

2 years ago

3.1.78

2 years ago

3.1.77

2 years ago

3.1.76

2 years ago

3.1.75

2 years ago

3.1.74

2 years ago

3.1.73

2 years ago

3.1.72

2 years ago

3.1.71

2 years ago

3.1.70

2 years ago

3.1.69

2 years ago

3.1.68

2 years ago

2.1.68

2 years ago

2.1.67

2 years ago

2.1.66

2 years ago

2.1.65

2 years ago

2.1.64

2 years ago

2.1.63

2 years ago

2.1.62

2 years ago

2.1.61

2 years ago

2.1.60

2 years ago

2.1.59

2 years ago

2.1.58

2 years ago

2.1.57

2 years ago

2.1.56

2 years ago

2.1.55

2 years ago

2.1.54

2 years ago

2.1.53

2 years ago

2.1.52

2 years ago

2.1.51

2 years ago

2.1.50

2 years ago

2.1.49

2 years ago

2.1.48

2 years ago

2.1.47

2 years ago

2.1.46

2 years ago

2.1.45

2 years ago

2.1.44

2 years ago

2.1.43

2 years ago

2.1.42

2 years ago

2.1.41

2 years ago

2.1.40

2 years ago

2.1.39

2 years ago

2.1.38

2 years ago

2.1.37

2 years ago

2.1.36

2 years ago

2.1.35

2 years ago

2.1.34

2 years ago

2.1.33

2 years ago

2.1.32

2 years ago

2.1.31

2 years ago

1.1.31

2 years ago

1.1.30

2 years ago

1.1.29

2 years ago

1.1.28

2 years ago

1.1.27

2 years ago

1.1.26

2 years ago

1.1.25

2 years ago

1.1.24

2 years ago

1.1.23

2 years ago

1.1.22

2 years ago

1.1.21

2 years ago

1.1.20

2 years ago

1.1.19

2 years ago

1.1.18

2 years ago

1.1.17

2 years ago

1.0.17

2 years ago

1.0.16

2 years ago

1.0.15

2 years ago

1.0.14

2 years ago

1.0.13

2 years ago

1.0.12

2 years ago

1.0.11

2 years ago

1.0.10

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

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