Monday, June 3, 2024
 Popular · Latest · Hot · Upcoming
83
rated 0 times [  88] [ 5]  / answers: 1 / hits: 16918  / 12 Years ago, fri, september 28, 2012, 12:00:00

I'm having problems on Firefox 15 and Chrome 21 with the following code:



setInterval(function () { console.log('test') }, 300000000000)


On both browsers, the function is run right away repeats very quickly. Sure, that's a big number (representing about 10 years from now), but I wouldn't expect it to be treated as a tiny or negative number. I haven't seen a maximum allowed delay in any documentation. Does anyone know if there's a standard max, or if this is just the browsers being funny?


More From » setinterval

 Answers
41

I can't find any documentation at the moment, but I wouldn't be surprised if the timer value had to fit in a 32-bit signed integer.


[#82866] Wednesday, September 26, 2012, 12 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
zainsagez

Total Points: 555
Total Questions: 99
Total Answers: 96

Location: Honduras
Member since Sat, Jul 24, 2021
3 Years ago
zainsagez questions
;