javascript isempty array es6 code example
Example 1: javascript not empty array not string
if (Array.isArray(array) && array.length) {
// array exists and is not empty
}
Example 2: empty array length javascript
empty array check javascript
if (Array.isArray(array) && array.length) {
// array exists and is not empty
}
empty array check javascript