npm.io
0.1.0 • Published 9 years ago

tinyajax

Licence
MIT
Version
0.1.0
Deps
0
Vulns
0
Weekly
0
DeprecatedThis package is deprecated

tinyajax

Install

$ npm install tinyajax --save
$ bower install tinyajax

Usage

var ajax = require('tinyajax');

ajax(src, function(err, text) {
  ...
});

// sync
ajax(src, function(err, text) {
  ...
}, true);


// option
ajax(src, function(err, text) {
  ...
}, {
  sync: false,
  mimetype: 'application/json',
  headers: {
  	'X-Some-Header': 'value'
  },
  payload: {
    key: 'value'
  }
});

Keywords