makearr
v1.0.2
Published
Easily create arrays
Downloads
4
Readme
makearr
Install
npm i makearr
Usage
CommonJS
const makearr = require('makearr');
makearr.makearr<number>(3, 1); // => [1, 1, 1]
makearr.makearr2<number>(3, 2, 1);
// =>
// [
// [1, 1]
// [1, 1]
// [1, 1]
// ]
ESModule
import { makearr, makearr2 } from 'makearr';
makearr<number>(3, 1); // => [1, 1, 1]
makearr2<number>(3, 2, 1);
// =>
// [
// [1, 1]
// [1, 1]
// [1, 1]
// ]