@extra-iterable/shift.min

Removes first value. :package: :smiley_cat: :running: :vhs: :moon: :scroll: :newspaper: :blue_book:

Usage no npm install needed!

<script type="module">
  import extraIterableShiftMin from 'https://cdn.skypack.dev/@extra-iterable/shift.min';
</script>

README

Removes first value. :package: :smiley_cat: :running: :vhs: :moon: :scroll: :newspaper: :blue_book:

Similar: push, pop, shift, unshift.

This is part of package extra-iterable.

This is browserified, minified version of @extra-iterable/shift.
It is exported as global variable iterable_shift.
CDN: unpkg, jsDelivr.


iterable.shift(x);
// x: an iterable
const iterable = require("extra-iterable");

var x = [1, 2, 3];
[...iterable.shift(x)];
// [ 2, 3 ]

var x = [1, 2, 3, 4];
[...iterable.shift(x)];
// [ 2, 3, 4 ]


References