Skip to content
Simple/dumb promise wrapper for superagent
JavaScript
Find file
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
test
.gitignore
LICENSE
Makefile
README.md
browser-test.opts
browser_test.js
component.json
index.js
index_test.js
package.json

README.md

superagent-promise

Simple/dumb promise wrapper for superagent. Both superagent and promise are peerDependencies.

Usage

var agent = require('superagent-promise');

// method, url form
agent('GET', 'http://google.com').
  end().
  then(function onResult(res) {
  });

// helper functions: get, head, patch, post, put, del
agent().
  put('http://myxfoo', 'data').
  end().
  then(function(res) {
  });
Something went wrong with that request. Please try again.