// Type definitions for react-timeout 1.1 // Project: https://github.com/plougsgaard/react-timeout // Definitions by: Kerwyn Rojas // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.8 /// import * as React from 'react'; export = ReactTimeout; declare function ReactTimeout( SourceComponent: React.ComponentClass | React.StatelessComponent ): React.ComponentClass; declare namespace ReactTimeout { type Timer = NodeJS.Timer | number; type Id = number; interface ReactTimeoutProps { setTimeout?: (callback: (...args: any[]) => void, ms: number, ...args: any[]) => Timer; clearTimeout?: (timer: Timer) => void; setInterval?: (callback: (...args: any[]) => void, ms: number, ...args: any[]) => Id; clearInterval?: (id: Id) => void; setImmediate?: (callback: (...args: any[]) => void, ...args: any[]) => Id; clearImmediate?: (id: Id) => void; requestAnimationFrame?: (callback: (...args: any[]) => void) => Id; cancelAnimationFrame?: (id: Id) => void; } }