Package Exports
- js-data-http
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (js-data-http) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme

js-data-http
This repo contains HTTP adapters for js-data:
- js-data-http - HTTP (XHR, includes [axios][axios]) adapter for js-data in the
browser. Capable of using
window.fetch
instead of axios. - js-data-fetch - Same as js-data-http but doesn't include axios and will use
window.fetch
if available and if you don't provide your own http library. - js-data-http-node - Same as js-data-http but runs on Node.js. Depends on axios and will use axios unless you provide a different http library.
Tested on IE9, Chrome 46, Firefox 41 & Safari 7.1 using
To get started, visit http://js-data.io.
Table of contents
- Quick start
- Dependencies
- Guides and Tutorials
- API Reference Docs
- Community
- Support
- Contributing
- License
Quick Start
npm install --save js-data js-data-http
or bower install --save js-data js-data-http
.
npm install --save axios js-data js-data-http-node
ES6
// Doesn't make much sense to use DataStore on the server
import {Container} from 'js-data'
import HttpAdapter from 'js-data-http-node'
const adapter = new HttpAdapter()
const container = new Container()
container.registerAdapter('http', adapter, { default: true })
container.defineMapper('school')
container.defineMapper('student')
container.find('school', 1).then(function (school) {
// ...
})
Dependencies
js-data-http
bundles axios and depends on js-data
. js-data-fetch
depends
on js-data
. js-data-http-node
depends on js-data
and optionally axios.
Guides and Tutorials
Get started at http://js-data.io
API Reference Docs
Community
Support
Contributing
License
The MIT License (MIT)
Copyright (c) 2014-2016 js-data-http project authors