got-promise

Promise wrapper of sindresorhus/got

MIT 10 个版本
安装
npm install got-promise
yarn add got-promise
pnpm add got-promise
bun add got-promise
README

got-promise Build Status

Deprecated: Use got directly, since it now have Promise API :tada:.

Install

$ npm install --save got-promise

Usage

var got = require('got-promise');

got('google.com')
	.then(function (res) {
		console.log(res.body);
	})
	.catch(function (err) {
		console.error(err);
		console.log(err.response.body);
	});

got.post('google.com'); // => Promise

API

Look at sindresorhus/got.

License

MIT © Vsevolod Strukchinsky

版本列表
5.0.0 2015-07-25
4.1.0 2015-05-09
4.0.0 2015-05-06
3.0.1 2015-04-20
3.0.0 2015-04-20
2.1.3 2015-04-20
2.1.2 2015-04-20
2.1.1 2015-04-19
2.0.0 2015-04-08
1.0.0 2015-04-05