Move an array item to a different position within array bounds
npm install array-move-item> Move an array item to a different position within array bounds
```
$ npm install --save array-move-item
Returns a new array with the item moved to the new position.
If the target index is greater than the length of the array, the item is
moved to the end of the array.
If the target index is negative and greater than the length of the array, the item is
moved to the start of the array.
`js
var moveItem = require('array-move-item');
const items = ['a', 'b', 'c'];
moveItem(items, 1, 2);
//=> ['a', 'c', 'b']
moveItem(items, -1, 0);
//=> ['c', 'a', 'b']
moveItem(items, -2, -10);
//=> ['b', 'a', 'c']
``
MIT © Illarion Koperski