@extra-array/size.min

Counts the number of values. :package: :smiley_cat: :running: :vhs: :moon: :scroll: :newspaper: :blue_book:

Usage no npm install needed!

<script type="module">
  import extraArraySizeMin from 'https://cdn.skypack.dev/@extra-array/size.min';
</script>

README

Counts the number of values. :package: :smiley_cat: :running: :vhs: :moon: :scroll: :newspaper: :blue_book:

Similar: index, indexRange, size, isEmpty.

This is part of package extra-array.

This is browserified, minified version of @extra-array/size.
It is exported as global variable array_size.
CDN: unpkg, jsDelivr.


array.size(x, [i], [I]);
// x: an array
// i: start index (-ve: from right) (0)
// I: end index (-ve: from right) (X)
const array = require("extra-array");

var x = [2, 4, 6, 8];
array.size(x);
// 4

array.size(x, 1);
// 3

array.size(x, 1, 3);
// 2


References