1.0.21 • Published 4 days ago

@devtea2026/quisquam-ea-vero-temporibus v1.0.21

Weekly downloads
-
License
MIT
Repository
github
Last release
4 days ago

@devtea2026/quisquam-ea-vero-temporibus Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

An ES spec-compliant Array.prototype.slice 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.slice depends on a receiver (the “this” value), the main export takes the array to operate on as the first argument.

Engines where this is needed

Note: this list is not exhaustive.

  • Safari 10 - 13
  • Chrome 48+ (v8 bug)
  • node 6+

Example

var slice = require('@devtea2026/quisquam-ea-vero-temporibus');
var assert = require('assert');

var a = [1, 2, 3];
assert.deepEqual(slice(a, 1, 2), [2]);
assert.deepEqual(slice(a, -2), [2, 3]);
var slice = require('@devtea2026/quisquam-ea-vero-temporibus');
var assert = require('assert');
/* when Array#slice is not present */
delete Array.prototype.slice;
var shimmed = slice.shim();
assert.equal(shimmed, slice.getPolyfill());
assert.equal(shimmed, Array.prototype.slice);
assert.deepEqual([1, 2, 3].slice(1, 2), slice([1, 2, 3], 1, 2));
var slice = require('@devtea2026/quisquam-ea-vero-temporibus');
var assert = require('assert');
/* when Array#slice is present */
var shimmed = slice.shim();
assert.equal(shimmed, Array.prototype.slice);
assert.deepEqual([1, 2, 3].slice(1, 2), slice([1, 2, 3], 1, 2));

Tests

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

modulesettingsframeworkInt32Arrayes-shim APIshellsescall-bindclientl10nwatchFilemapes8streamupeast-asian-widthartgradients css3groupBydatewatcherlazychromiumconcurrencytestjsdompatchi18npackage managerflattenbundlingimmutabletraversefasttypestermstringifierutilgetOwnPropertyDescriptorconfigtypesafewordbreakboundESRxJSeslintconfigArray.prototype.flatprivateTypeScripta11yfpsdomES2016containss3stableoptimizercompilerwhatwgawsfixed-widthECMAScript 2023iefullreact-testing-librarymkdirsreact-hook-formparenttoolsomitappoptionerror-handlingkeyratelimitdirectorymake dirasciiserializertypedeepdotenvconsumequeueredux-toolkitinternal slotrestfulsetsameValueZeropredictabletelephonelogger[[Prototype]]arrayYAML0gdprcallbacklimitedfilteroffsetnopejoienvPromisermdirfromless.jses5vestdatastructureinferencematchAllworkflowassertioncollectionglobassignlengthfastcopysinatrasidemetadataajvtoStringTagtaperegexpflatMapES2017cryptcoregradients csscompile lesspolyfillsomepreserve-symlinkstaskmimetypesRFC-6455libphonenumbertyped arraydataViewvpcsyntaxUnderscoreshamwidthdeepcopycloudsearchuuidObject.getPrototypeOfbyteOffsetsqstouchapolloansihashcircularhardlinksunicodebootstrap csssafebootstrap lessworkerstarterqueueMicrotaskenderformatRegExp#flagsparentsdayjstestingspinnersasserttextfilegetonceoptimistes7setterpostcssInt8ArrayargsCSSdependenciesparsingfunctionsless compilershimbufferCSSStyleDeclarationyamlarraysgetoptterminaleslintwhichconnectamazonvaluescharactersponyfillstylingreadablestreamcommand-linefseventsfetchsignalsArray.prototype.containsvalidmulti-packagenamecomparepipetostringtagclass-validatorsharedsymlinksharedarraybuffercss-in-jsutilitymergeprogressmobileenvironmentshasOwnPropertywatchtoArrayrdstrimStartauthenvironmentkarmaclassnamesObject.fromEntriesextendSymbol.toStringTagReactiveExtensionsgraphqltakeflagsbrowserlistinterruptsstdlibserializationhttpbusydiffObservableprocesstrimLeftmkdirarktypeprototypeajaxArray.prototype.includesRxdatanegativelistenersdeletewalkiterateES3propertynested cssperformantenumerabledeep-clonepicomatchdebugesMapvalidationfindLastIndexbyteweaksetsymlinksform-validationpositiveObject.isconsoleArray.prototype.findLastIndexpreprocessorcorslookhttpslog$.extendsequencefullwidthJSON-Schematypanion@@toStringTagPushjsonpathtypeerrorWeakSeteventDispatcherdynamodbbcryptHyBibeanstalkexpressiontslibnamesrangeerrorstreamsextraformlinkstreams2phoneES2022ESnextcryptoinvariantArray.prototype.flattenmoduleszeroreusesignalastnodedescriptorawaitcensorapifast-deep-copytddtestercss nestingtoobjectxtermnegative zeroimportexportresolveminimalkeysrobustpnpm9Function.prototype.nameString.prototype.trimReflect.getPrototypeOfio-tsvariableseslintpluginhookformcloudfrontec2findLastparsesymbolscoerciblewgetcall-boundObject.keyspackage.jsonautoscalingrgbArray.prototype.flatMapmapreducedirchailrumonoreposigtermsymbolperformancejsonsortreducerloggingcss lessstatuscliwarningdeepcloneInt16Arraywalkingjshintvaluecloudformationcloudtrailkinesisspecownjsxes2018slotincludesbrowserslistArray.prototype.filtershrinkwrapArrayBuffer#slicees2017columnirqbundlerparserArrayBuffer.prototype.slicereduximportECMAScript 7utilitiespostcss-pluginjsdiffstringifyautoprefixeropenerrorfast-cloneutil.inspectlimitinrm -rfString.prototype.matchAlliterationBigUint64ArrayschemesortedloadbalancingxhrlinewrapReactiveXclassnamecolorsquoteshebangnodejsprefixregular expressionsmakerecursivecallbindproxyECMAScript 2016typeof.envescapegetPrototypeOfcss variableendpointmomentequalityWebSocketsregexTypedArraydefinePropertypackagebrowserdescriptorsUint8ClampedArraytc39searchfast-copyreadableduplexkoreanhandlersprunehooksIteratorcloudwatchaccessorFloat32ArraybufferscreatereplayUint8Arraycollection.es6styleconcatawesomesaucestringreact-hooksfind-upsyntaxerroriteratorregular expressionserializequerystringbatchisvalidateinputES5256throttleES2018fluxcode pointsnativereactecmascriptfindupsuperstructregularrequestelbargumentlanguagebreakreal-timeinstalltypedarraysmatchtapglobalstypedarrayzodconfigurablettyES7cjkgettercheckES2021StyleSheetdebuggercopystoragegatewayECMAScript 2021webdefinetoSortedeventsfunctionmruarraybufferfindECMAScript 5bindfile systemindicatorexitairbnbremoveECMAScript 2022dataviewencryptionargparsemimeclasseslook-upefficientyuprfc4122ES2015sigintspinnerpersistentjavascripttrimRightes6ES2023immereventEmitter__proto__rateECMAScript 2020installerpasswordnumberrouterObject.valuestypedbyteLengthviewfastclonecloneglacierglobaloperating-systemes-abstractmiddlewarefoldercore-jshas-ownJSONchromeObservablestrimbanneres2015outputliveURLebsmatchesloadingObject.assignidentifiersequalsuperagentmoverandomObject.definePropertyArrayformslesscssassertsprotobufvisualTypeBoxES2020pushmacosdeep-copyeveryauthenticationstylesexit-codetsmochaprotocol-buffersconcatMaplastroute53urlwaitArray.prototype.findLastfunctionalvariables in cssquerygetintrinsicentriessnsArrayBufferelasticacheredactObject.entrieselmworkspace:*colorwatchingUint16ArraymixinssetPrototypeOfswfvarsfast-deep-clonechineseqsdropmime-dbSetStreamcallspeedjapanesepropertieswritableisConcatSpreadableemrcurlRegExp.prototype.flagsECMAScript 2015jestformattingstructuredClonepackagesexpressSymbolidjasmine
1.0.21

4 days ago

1.0.20

5 days ago

1.0.19

6 days ago

1.0.18

7 days ago

1.0.17

8 days ago

1.0.16

9 days ago

1.0.15

10 days ago

1.0.14

11 days ago

1.0.13

12 days ago

1.0.12

13 days ago

1.0.11

14 days ago

1.0.10

15 days ago

1.0.9

16 days ago

1.0.8

17 days ago

1.0.7

18 days ago

1.0.6

19 days ago