0.1.2 • Published 6 years ago

rest-api-fetcher v0.1.2

Weekly downloads
3
License
ISC
Repository
github
Last release
6 years ago

rest-api-fetcher

Usage example:

var rest_api_fetcher = require('rest-api-fetcher')

var codejquery = rest_api_fetcher.createRoute('http://code.jquery.com', ['jquery-3.3.1.js'])
codejquery.get()

var routes = [
    'posts',
    'comments'
]

var api = rest_api_fetcher.createRoutes('https://jsonplaceholder.typicode.com', routes)

// .get(id, subroute, query)

api.posts.get()
api.comments.get()

api.posts.get(1)
api.posts.get(1, 'comments')

api.comments.get(null, null, { postId: 1 })
0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago