This package has been deprecated

Author message:

This version is replaced by @travetto/net

@travetto/util

0.3.13 • Public • Published

travetto: Util

Common utilities for executing HTTP requests and any other future catch alls.

HTTP Requests

The http request functionality exists to allow for simple usage of the node http and https modules. This functionality exists, in lieu of alternatives, as a means to provide the smallest footprint possible. The logic itself is simple:

request(opts: http.RequestOptions & { url: string }, data?: any): Promise<string>;
request(opts: http.RequestOptions & { url: string, pipeTo: any }, data?: any): Promise<http.IncomingMessage>;
requestJSON<T, U>(opts: http.RequestOptions & { url: string }, data?: U): Promise<T>;

Package Sidebar

Install

npm i @travetto/util

Homepage

travetto.io

Weekly Downloads

2

Version

0.3.13

License

MIT

Unpacked Size

7.29 kB

Total Files

6

Last publish

Collaborators

  • arcsine