on master help sign in
Add Utils.isJSArray for #576
20bb322Christian Widera
libraries/Native/Utils.js+5
@@ -210,6 +210,10 @@ Elm.Native.Utils.make = function(elm) {
210 return Tuple2(posx, posy);
210 return Tuple2(posx, posy);
211 }
211 }
212
212
213+ function isJSArray(a) {
214+ return Array.isArray(a);
215+ }
216+
213 return elm.Native.Utils.values = {
217 return elm.Native.Utils.values = {
214 eq:eq,
218 eq:eq,
215 cmp:cmp,
219 cmp:cmp,
@@ -229,6 +233,7 @@ Elm.Native.Utils.make = function(elm) {
229 mod : F2(mod),
233 mod : F2(mod),
230 htmlHeight: F2(htmlHeight),
234 htmlHeight: F2(htmlHeight),
231 getXY: getXY,
235 getXY: getXY,
236+ isJSArray: isJSArray,
232 toFloat: function(x) { return +x; }
237 toFloat: function(x) { return +x; }
233 };
238 };
234};
239};