Utilities / Timeout
Call a function after a certain time has passed. Uses the window.setTimeout()
.
• new Timeout()
• Private
id: number
• Private
is_active: boolean
▸ clear(): void
Cancels the timeout.
void
▸ isActive(): boolean
Returns whether the timeout is active or not.
boolean
▸ start(functionToCall
, interval
): void
Starts the timeout. If there was an active timeout already, that one is canceled.
Name | Type |
---|---|
functionToCall |
() => void |
interval |
number |
void