Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zswang/h5ajax
Ajax of Mobile
https://github.com/zswang/h5ajax
ajax javascript mobile
Last synced: about 1 month ago
JSON representation
Ajax of Mobile
- Host: GitHub
- URL: https://github.com/zswang/h5ajax
- Owner: zswang
- License: mit
- Created: 2016-11-12T13:56:12.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2016-11-17T07:18:53.000Z (about 8 years ago)
- Last Synced: 2024-11-19T21:47:04.502Z (about 1 month ago)
- Topics: ajax, javascript, mobile
- Language: JavaScript
- Size: 11.7 KB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
h5ajax Ajax of Moblie
-----# [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Coverage Status][coverage-image]][coverage-url]
Smaller than smaller.
无他,就是小
## 使用方法
### GET
```js
h5ajax.get('http://localhost/user/info', function(err, json) {
console.log(JSON.stringify(json));
// > {"status":200,"data":{"user_id":30001,"name":"zswang"}}
// * done
});
```### POST
```js
h5ajax.post('http://localhost/user/info', { "code": "2016" }, function(err, json) {
console.log(JSON.stringify(json));
// > {"status":200,"data":{"user_id":30001,"name":"zswang","code":"2016"}}
// * done
});
```## License
MIT © [zswang](http://weibo.com/zswang)
[npm-url]: https://npmjs.org/package/h5ajax
[npm-image]: https://badge.fury.io/js/h5ajax.svg
[travis-url]: https://travis-ci.org/zswang/h5ajax
[travis-image]: https://travis-ci.org/zswang/h5ajax.svg?branch=master
[coverage-url]: https://coveralls.io/github/zswang/h5ajax?branch=master
[coverage-image]: https://coveralls.io/repos/zswang/h5ajax/badge.svg?branch=master&service=github