0.0.2 • Published 6 years ago
react-native-declarative-timer v0.0.2
react-native-declarative-timer
Declaratively create timers in your components.
Quick Access
- Installation
- Usage
- Properties
- Contributing
Installation
Install the module with:
npm install react-native-declarative-timer --save
Usage
In your code, simply require/import the module:
import Timer from 'react-native-declarative-timer';
// ...
<Timer func={funcToExecute} interval={60} />
// or wrap any single component (has no additional purpose, yet!)
<Timer func={funcToExecute} interval={60}>
...
</Timer>
Properties
Prop | Description | Default |
---|---|---|
interval | Interval in seconds | 1 |
func | The function to execute every interval seconds | null |
Top
Contributing
Feel free to do pull requests if a certain feature you want is missing. We accept all PR's that are enhancements to the project.