util-pusher-x

A simple pusher/concatenator utility.

MIT 4 个版本
安装
npm install util-pusher-x
yarn add util-pusher-x
pnpm add util-pusher-x
bun add util-pusher-x
README

Travis status Dependency status devDependency status npm version jsDelivr hits bettercodehub score Coverage Status

util-pusher-x

This pushes or concatenates into a new or existing array.

module.exports(arrayLike, [from], [target])

This pushes or concatenates into a new or existing array.

Kind: Exported member

Param Type Description
arrayLike ArrayLike The source.
[from] number The from source index.
[target] Array The target array.

Example

import pusher from 'util-pusher-x';

const x = [1, 2, 3];
console.log(pusher([4, 5, 6], 1, x)); // [1, 2, 3, 5, 6]
版本列表
1.0.3 2019-08-28
1.0.2 2019-08-20
1.0.1 2019-08-16
1.0.0 2019-08-16