1.2.0 • Published 2 years ago

easylinkedlist v1.2.0

Weekly downloads
-
License
GPL-3.0
Repository
github
Last release
2 years ago

Easy-List: Simple Doubly Linked-List implementation

Because I found out JavaScript didn't have linked lists...

Getting Started

ES6 is required.

Installation

npm install easy-list@latest

Importing

Supports both Typescript and Javascript
Typescript importing

import { easyLinkedList } from 'easylinkedlist' 

const list = new easyLinkedList<Number>();

CommonJS importing

const { easyLinkedList } = require('easylinkedlist');
const list = new easyLinkedList();

Basic Usage

list.push(1).push(2).push(3).push(4); // [ 1, 2, 3, 4 ]
list.pop(); // [ 1, 2, 3 ]
list.shift(); // [ 2, 3 ]
list.unshift(1).unshift(0); // [ 0, 1, 2, 3 ]
list.isEmpty(); // false
list.set(1, 4); // [ 0, 4, 2, 3 ]

Documentation

1.2.0

2 years ago

1.1.0

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago