securityos/node_modules/regl/lib/util/loop.js

8 lines
139 B
JavaScript

module.exports = function loop (n, f) {
var result = Array(n)
for (var i = 0; i < n; ++i) {
result[i] = f(i)
}
return result
}