Apply store pattern to track global app state
[vchess.git] / client / src / utils / array.js
index a8466c6..b438eaa 100644 (file)
@@ -22,3 +22,8 @@ export function init(size1, size2, initElem)
 {
   return [...Array(size1)].map(e => Array(size2).fill(initElem));
 }
+
+export function range(max)
+{
+  return [...Array(max).keys()];
+}