mirror of
https://github.com/morhetz/gruvbox.git
synced 2025-11-15 23:03:46 -05:00
1.2 KiB
1.2 KiB
Turn anything into an array
Install
$ npm install --save array-ify
Usage
var arrayify = require('array-ify');
arrayify('unicorn');
//=> ['unicorn']
arrayify(['unicorn']);
//=> ['unicorn']
arrayify(null);
//=> [null]
arrayify(undefined);
//=> [undefined]
Related
- arrify - Convert a value to an array
The difference that is this module does NOT turn null or undefined to an empty array.
License
MIT © Steve Mao