array-seq

functionsince v0.0-927Edit
(array-seq array)
(array-seq array i)

Creates a seq from a JavaScript array or array-like object, starting at index i if given.


Examples:

(array-seq #js [1 2 3])
;;=> (1 2 3)

(array-seq #js [1 2 3] 1)
;;=> (2 3)

Also works on Array-like objects, like NodeList.

(array-seq (js/document.querySelectorAll "div"))
;;=> ...

See Also:


Source docstring:
Create a seq from a JavaScript array.
Source code @ clojurescript:src/main/cljs/cljs/core.cljs
(defn array-seq
  ([array]
     (prim-seq array 0))
  ([array i]
     (prim-seq array i)))