1.0.1 ā¢ Published 4 years ago
react-spinnter v1.0.1
React Spinnter š
A friendly interactive spinner made using āļø React.
Demo
Features
- Making wait-time less frustrating by transitioning through friendly texts with emojis
- Ability to cancel triggered request
Coming soon š :
- Custom content for each step
- Custom duration for each step
- Support for all HTTP requests
- Selection of fonts
- Custom colors
Usage
Installing dependency
š¦ Will be available on npm soon ...
Quick hands-on
function App() {
return (
<div className="App">
<Spinnter demo={true} url={''} onSuccess={() => {}} onFailure={() => {}} />
</div>
);
}
Standard usage
function App() {
const handleSuccess = (data: any) => {
// Do something with successful response
}
const handleFailure = (message: any) => {
// Do something in case of failure
}
return (
<div className="App">
<Spinnter url={/* your url here */} onSuccess={handleSuccess} onFailure={handleFailure} />
</div>
);
}
Asking Questions
If you have a question, feel free to contact me on this email ali.rafiq.it@gmail.com
License
This project is licensed under the GPL-3.0 License. See the LICENSE file for more info.