// @flow
const foo: number = setTimeout(() => {}, 300);
const bar: number = setInterval(() => {}, 300);
3: const foo: number = setTimeout(() => {}, 300);
^ TimeoutID. This type is incompatible with
3: const foo: number = setTimeout(() => {}, 300);
^ number
4: const bar: number = setInterval(() => {}, 300);
^ IntervalID. This type is incompatible with
4: const bar: number = setInterval(() => {}, 300);
^ number
Error does not exist in
0.62.0https://flow.org/try/#0PQKgBAAgZgNg9gdzCYAoVBjOA7AzgFzCjjgC4xsBXAWwCMBTAJzAF4xd78AVAS2vriV8ACmEBKVgD4wAbwC+AGjABmAAyqxAbkw4CYWgENG5KnSat2nAJLZ8TAG4GYoiS2nylajZqA