example.js 359 B

1234567891011121314151617181920212223
  1. var lt = require('./')
  2. /*
  3. Timeouts
  4. */
  5. lt.setTimeout(function() {
  6. console.log('in a long time')
  7. }, Number.MAX_VALUE)
  8. lt.setTimeout(function() {
  9. console.log('2 seconds')
  10. }, 2000)
  11. /*
  12. Intervals
  13. */
  14. lt.setInterval(function() {
  15. console.log('long interval')
  16. }, Number.MAX_VALUE)
  17. lt.setInterval(function() {
  18. console.log("2 second interval")
  19. }, 2000)