- Notifications
You must be signed in to change notification settings - Fork 159
Closed
Description
WindowTimers.setTimeout() has the following signature:
def setTimeout(handler: js.Any, timeout: js.Any, args: js.Any*): Int = ??? Some users (including myself) ran into a problem passing a block instead of a lambda. It would be helpful if the compiler could catch this on-the-fly. Therefore, I would advise changing it to:
def setTimeout(handler: () => Unit, timeout: Int): Int = ??? MDN also doesn't specify the additional parameters, which appear to be safe to drop.
In the unlikely event that the user wants to use the untyped version, he can just resort to js.Dynamic.global.setTimeout().
Metadata
Metadata
Assignees
Labels
No labels