| 6 | import { MatrixInterface } from './MatrixInterface'; |
| 7 | |
| 8 | const isPerfectSquare = arr => { |
| 9 | const sqDimention = Math.sqrt(arr.length); |
| 10 | if (sqDimention % 1 !== 0) { |
| 11 | throw new Error('Array length must be a perfect square.'); |
| 12 | } |
| 13 | return true; |
| 14 | }; |
| 15 | |
| 16 | export let GLMAT_ARRAY_TYPE = Array; |
| 17 | export let isMatrixArray = x => Array.isArray(x); |
no outgoing calls
no test coverage detected