Check for Arrays in JavaScript

JavaScript is a great language, but it’s far from perfect. One among many other drawbacks is JavaScript’s nature of assigning and handling datatypes. typeof for any non-trivial datatype returns object which makes it a bit unintuitive to detect whether or not a given variable contains an array. Here is how to check for Arrays in JavaScript…

Weiterlesen