Checks if the given argument is an array.

Type signature

(value?: any) => boolean

Examples

is([1, 2, 3]);
// ⇒ true
Try in REPL
is({ a: 5 });
// ⇒ false
Try in REPL

Questions

  • How to check if a value is an array?

TypeScript sourceJavaScript source