make-array
makeArray(element)
Parameters
- element
{ArrayLike|Object}
:any array-like or object data structure
Returns
{Array}
:
a JavaScript array object with the same elements as the passed-in ArrayLike
makeArray takes any array-like object (can-list, NodeList, etc.) and converts it to a JavaScript array
var makeArray = require("can-util/js/make-array/make-array");
makeArray({0: "a", length: 1}); //-> ["a"]