Skip to content
Subhajit Sahu edited this page Jun 18, 2020 · 13 revisions

Gets lists without the first entry. 🏃 📼 📦 🌔 📒

Similar: head, tail.

lists.tail(x);
// x: lists
const lists = require('extra-lists');

var x = [['a', 'b', 'c'], [1, 2, 3]];
lists.tail(x).map(c => [...c]);
// [ [ 'b', 'c' ], [ 2, 3 ] ]

var x = [['a'], [1]];
lists.tail(x).map(c => [...c]);
// [ [], [] ]

references

Clone this wiki locally