Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 
 
 
 
 

readme.md

array-utils

Few random array utils

Installation

// npm
npm install @andrewnoyes/array-utils --save

// yarn
yarn add @andrewnoyes/array-utils

Usage

import { immutablePop, immutablePush, reorder } from '@andrewnoyes/array-utils';

// pop
const popResult = immutablePop([1, 2, 3]); // [1, 2]

// push
const pushResult = immutablePush([1, 2, 3], 4); // [1, 2, 3, 4]

// reorder
const reorderResult = reorder([1, 2, 3], 0, 2); // [2, 3, 1]

About

Collection of various array utility functions

Resources

License

Packages

No packages published
You can’t perform that action at this time.