4.6.115 • Published 2 years ago

@diotoborg/laboriosam-eos v4.6.115

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

@diotoborg/laboriosam-eos Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

An ES2015 spec-compliant Array.prototype.copyWithin 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 spec.

Because Array.prototype.copyWithin depends on a receiver (the “this” value), the main export takes the array to operate on as the first argument.

Example

var copyWithin = require('@diotoborg/laboriosam-eos');
var assert = require('assert');

var arr = [1, 2, 3, 4, 5];
assert.deepEqual(copyWithin(arr, 0, 3), [4, 5, 3, 4, 5]);
assert.deepEqual(arr, [4, 5, 3, 4, 5]);
var copyWithin = require('@diotoborg/laboriosam-eos');
var assert = require('assert');
/* when Array#copyWithin is not present */
delete Array.prototype.copyWithin;
var shimmedCopyWithin = copyWithin.shim();
assert.deepStrictEqual(shimmedCopyWithin, copyWithin.getPolyfill());

var arr = [1, 2, 3, 4, 5];
assert.deepEqual(copyWithin(arr, 0, 3), [4, 5, 3, 4, 5]);
assert.deepEqual(arr, [4, 5, 3, 4, 5]);
var copyWithin = require('@diotoborg/laboriosam-eos');
var assert = require('assert');
/* when Array#copyWithin is present */
var shimmedCopyWithin = copyWithin.shim();
assert.equal(shimmedCopyWithin, Array.prototype.copyWithin);

var arr = [1, 2, 3, 4, 5];
assert.deepEqual(copyWithin(arr, 0, 3), [4, 5, 3, 4, 5]);
assert.deepEqual(arr, [4, 5, 3, 4, 5]);

Tests

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

dragishasOwnposeconstelbrandomdiffponyfillmetadatadataObject.keysreduxPromiseremovefastimmutablestylessettingsintrinsicspawn6to5l10nworkertypedarrayStreamsconfigurablepurevarRxfnmatchyamlpolyfillrequirewalkingsyntaxerror@@toStringTagECMAScript 2016apipackage managerhascallbounddeterministicArray.prototype.containses7color3dboundutilslocationWebSocketsfiletacitebsArray.prototype.flatMaprm -frclonetextObject.valuesbinaryfunction.lengthprotocol-buffersglobalThisaccessibilityinspecteventsunicodecssglobalqueryutilitiesec2higher-ordertypetouchcollectionacornbufferMicrosoftistanbulwidthpropharmonyrm -rfcolourpatchdeepclonelook-up_.extendwhatwgtypesclassnamesredactvalidtaketscheckcloudfronttc39browserslistPushcore-jsfunctionalmake dirgetPrototypeOfargsfast-cloneenvsymlinksxmlgesturescommanderendpointpusheffect-tsmoduleloadbalancingrdsformstarteridentifierscallbackjsonjasminewebfunctiontypescriptastxtermruntimepruneSetomiteventDispatcherfastcopyArray.prototype.includesarktypeES2019argvgdprURLupnameseventEmitterlinkperformancehashregexpostcss-pluginstringifycloudwatchidleECMAScript 2017tapenpmignoresqsWeakSeturlvarsstringspecamazonrecursivetimereuseregularframeworkrgbsortedECMAScript 2021ownxhr256ArrayBuffer#slicedirRxJSpluginvalidatorUint8ClampedArrayformstyped arrayhooksfromhardlinks0descriptorparentmocharouterECMAScript 2020jsonschemaserializefindLastIndexES3class-validatorgraphqlreact-hook-form$.extendwindowfull-widthnumberidtoolkitsubprocesspinoestreeshrinkwrapsyntaxwhichasynccall-bindwgeteslintpluginstreamsObservableArray.prototype.flatsharedslotiemapBigUint64ArraywaitECMAScript 2015dropkeyfetchcreategroupBybddtypesafeapollomatchredux-toolkitYAML__proto__workflowreworkObject.assigncloudsearches5Float64Arraypyyamlfpssymboles2017progressECMAScript 5agentanimationtoStringTagcoretermtypeerrorString.prototype.trimESnextES7validationchinesewaapijestpathflattenpositivefilterspinnercallbindchaiinstrumentationhas-ownsesmodulesavaphonedeep-clonestoragegatewayTypedArrayhtmlRegExp#flagsinstallbinvariableslockfileformattestcensorrangeerrortestingObject.definePropertybabel-coreclientArray.prototype.filterlistenersmergeredirectreducemonorepoecmascriptoutputmapreducepackage.jsongitignoreReactiveExtensionsfastclonecolumnsimportlintstreampackageelasticacheprocessequalitydateramdaserializerArray.prototype.findLastbyteOffseti18nvestshebangawesomesauceTypeScriptsimpledbimmerresolveform-validationequalweakmapprivate datalookes-shimsvisualJSON-Schemasource mapECMAScript 2023figletURLSearchParamsfullwidthmkdirregular expressionsinatra.gitignoremomentimportexportdefinePropertyjsdomsearches-shim APIqsArrayBuffercss-in-jsSymbolschemeappjson-schema-validatorStreamfindupdependency managermkdirsutilityexpressjsdayjstypanionmkdirpsnscompilerFloat32ArrayfpprettyIteratorfast-deep-clone[[Prototype]]ECMAScriptrestfulyupvalidatepicomatchmatchescharactersmobileObservablesoptionemitutilES2020weaksetESfast-copyprotoObject.entriescurlinputcachechannelgetopt
4.5.115

2 years ago

4.6.115

2 years ago

4.5.114

2 years ago

4.5.113

2 years ago

4.5.112

2 years ago

4.5.111

2 years ago

4.5.110

2 years ago

4.5.109

2 years ago

4.4.109

2 years ago

4.4.108

2 years ago

4.4.107

2 years ago

4.4.106

2 years ago

4.4.105

2 years ago

4.4.104

2 years ago

4.4.103

2 years ago

4.4.102

2 years ago

4.4.101

2 years ago

4.4.100

2 years ago

4.4.99

2 years ago

4.4.98

2 years ago

4.4.97

2 years ago

4.4.96

2 years ago

4.4.95

2 years ago

4.4.94

2 years ago

4.4.93

2 years ago

4.4.92

2 years ago

4.4.91

2 years ago

4.4.90

2 years ago

4.4.89

2 years ago

4.4.88

2 years ago

4.4.87

2 years ago

4.4.86

2 years ago

4.4.85

2 years ago

4.3.85

2 years ago

4.3.84

2 years ago

4.3.83

2 years ago

4.3.82

2 years ago

4.3.81

2 years ago

4.3.80

2 years ago

4.3.79

2 years ago

4.3.78

2 years ago

4.3.77

2 years ago

4.3.76

2 years ago

4.3.75

2 years ago

4.3.74

2 years ago

4.3.73

2 years ago

4.3.72

2 years ago

4.3.71

2 years ago

4.3.70

2 years ago

3.3.70

2 years ago

3.3.69

2 years ago

3.3.68

2 years ago

3.3.67

2 years ago

3.3.66

2 years ago

3.3.65

2 years ago

3.3.64

2 years ago

3.2.64

2 years ago

3.2.63

2 years ago

2.2.63

2 years ago

2.2.62

2 years ago

2.2.61

2 years ago

2.2.60

2 years ago

2.2.59

2 years ago

2.2.58

2 years ago

2.2.57

2 years ago

2.2.56

2 years ago

2.2.55

2 years ago

2.2.54

2 years ago

2.2.53

2 years ago

2.2.52

2 years ago

2.2.51

2 years ago

2.2.50

2 years ago

2.2.49

2 years ago

2.2.48

2 years ago

2.2.47

2 years ago

2.2.46

2 years ago

2.2.45

2 years ago

2.2.44

2 years ago

2.2.43

2 years ago

2.2.42

2 years ago

2.2.41

2 years ago

2.2.40

2 years ago

2.2.39

2 years ago

2.2.38

2 years ago

2.2.37

2 years ago

2.2.36

2 years ago

2.2.35

2 years ago

2.2.34

2 years ago

2.2.33

2 years ago

2.2.32

2 years ago

2.2.31

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.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.0.20

2 years ago

1.0.19

2 years ago

1.0.18

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