Comparing version 0.0.2 to 0.0.3
{ | ||
"name": "loopcaster", | ||
"version": "0.0.2", | ||
"version": "0.0.3", | ||
"description": "When you need to print out something after `n` iterations.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -8,17 +8,17 @@ # loopcaster | ||
``` | ||
const LoopCaster = require('loopcaster'); | ||
const LoopCaster = require('loopcaster'); | ||
const SIZE = 128; | ||
const INTERVAL = 32; | ||
const SIZE = 128; | ||
const INTERVAL = 32; | ||
let caster = LoopCaster(SIZE, INTERVAL, function(index, data){ | ||
console.log(`Casting ${index} | ${data}`); | ||
}); | ||
let caster = LoopCaster(SIZE, INTERVAL, function(index, data){ | ||
console.log(`Casting ${index} | ${data}`); | ||
}); | ||
let sum = 0; | ||
let sum = 0; | ||
for( var i = 0; i < 128; i++ ){ | ||
sum += 2; | ||
caster.chant(sum); | ||
} | ||
for( var i = 0; i < 128; i++ ){ | ||
sum += 2; | ||
caster.chant(sum); | ||
} | ||
``` | ||
@@ -25,0 +25,0 @@ |
1938