afeiship / next-each-sibling

Each sibling for next.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

next-each-sibling

Each sibling for next.

version license size download

installation

npm install -S @jswork/next-each-sibling

usage

import '@jswork/next-each-sibling';

const indexes = [4, 8, 12];
const res = [];
nx.eachSibling(indexes, (cur, next) => {
  res.push([cur, next]);
});

// result
[
  [4, 8],
  [8, 12]
];

license

Code released under the MIT license.

About

Each sibling for next.

License:MIT License


Languages

Language:JavaScript 100.0%