rai

raix

Async request extensions for React

Showing:

Popularity

Downloads/wk

1

GitHub Stars

1

Maintenance

Last Commit

5yrs ago

Contributors

0

Package

Dependencies

3

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Readme

raix

Async request extensions for React

Install

npm install --save raix

How to use

import Raix from 'raix'
import Example from './components/Example'

export default Raix()(Example)

API

beforeRequest, afterRequest

example:

import Raix from 'raix'
import Example from './components/Example'

const beforeRequest = startRequest => setTimeout(startRequest, 1000)
const afterRequest = result => result.status === 200

export default Raix(beforeRequest, afterRequest)(Example)

init, data, formatter

example:

const init = {name: 'example'}
const data = {url: 'http://localhost:8000/api/test'}
const formatter = result => result.data

<RaixExample init={init} data={data} formatter={formatter} />

License

MIT

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Alternatives

No alternatives found

Tutorials

No tutorials found
Add a tutorial