release
alert
Auto-detect
Apple App Store
Rust Crate (Cargo)
Chocolatey Package
Docker Image
Debian Package (Bookworm)
Go Module
Ruby GEM
GitHub Repository
GitLab Repository
Maven Central
NPM Package
NuGet Package
Packagist Package
Python Package (PyPI)
VS Code Extension
WordPress Plugin
Search
/
Sign in
crcn/toarray.js
GitHub
github.com
Releases
0
Stars
2
convert any item to an array if it's not an array
Log in to subscribe
Releases
0
Links
1
Collections
0
Linked projects
toarray
NPM
I find myself writing `item = item instanceof Array ? item : [item]` a lot, so I decided to make a simple library to does it for me. A few examples: