README
rb-data-json-server
A Restboard data provider for JSON REST server
Getting started
import jsonServerDataProvider from 'rb-data-json-server'
const provider = jsonServerDataProvider('https://jsonplaceholder.typicode.com')
provider.getMany('posts')
.then(posts => console.log(posts))
.catch(err => console.error(err))
REST Dialect
Method | API call |
---|---|
getMany |
GET http://my.api.url/:resource |
getOne |
GET http://my.api.url/:resource/:id |
createOne |
POST http://my.api.url/:resource |
updateOne |
PATCH http://my.api.url/:resource/:id |
deleteOne |
DELETE http://my.api.url/:resource/:id |
Test
npm test
Contribute
If you want, you can also freely donate to fund the project development:
Have you found a bug?
Please open a new issue on:
https://github.com/zuck/rb-data-json-server/issues
Acknowledgements
This project is inspired by:
License
Copyright (c) Emanuele Bertoldi