Home > @unseenco/backstage-core > IRafDriver
IRafDriver interface
Public API for a custom requestAnimationFrame driver that advances Backstage's core ticker.
Signature:
typescript
export interface IRafDriverProperties
| Property | Modifiers | Type | Description |
|---|---|---|---|
| id | number | The id of the driver. This is used for debugging purposes. It's guaranteed to be unique. | |
| name | string | The name of the driver. This is used for debugging purposes. | |
| tick | (time: number) => void | This is called by the driver when it's time to tick forward. The time param is of the same type returned by performance.now(). | |
| type | 'Backstage_RafDriver_PublicAPI' | All raf derivers have have driver.type === 'Backstage_RafDriver_PublicAPI' |