UNPKG

@sophons/request

Version:

πŸš€ Probably the best Node.js HTTP request component, It also contains a rich stream processing

67 lines (47 loc) β€’ 1.8 kB
# @sophons/request > πŸš€ Probably the best Node.js HTTP request component, It also contains a rich stream processing ## ![ci](https://github.com/sophons-space/request/workflows/workflow/badge.svg) [![codecov](https://codecov.io/gh/sophons-space/request/branch/master/graph/badge.svg)](https://codecov.io/gh/sophons-space/request) ![npm](https://img.shields.io/npm/v/@sophons/request) ![](https://badgen.net/npm/types/@sophons/request) ![](https://badgen.net/npm/dm/@sophons/request) [![install size](https://packagephobia.com/badge?p=@sophons/request)](https://packagephobia.com/result?p=@sophons/request) ![](https://img.shields.io/npm/l/@sophons/request.svg) [![Known Vulnerabilities](https://snyk.io/test/npm/@sophons/request/badge.svg)](https://snyk.io/test/npm/@sophons/request) ## Features - Fast make an HTTP request with support for incoming Query - Fast make an HTTP form-data request with support for incoming Query - According to the URL, download the file to the local path - Conversion between streams and buffers - Converts the file to data in the specified format based on the URL **Inherited from [axios πŸ‘€](https://github.com/axios/axios)** - Make XMLHttpRequests from the browser - Make http requests from node.js - Supports the Promise API - Intercept request and response - Transform request and response data - Cancel requests - Automatic transforms for JSON data - Client side support for protecting against XSRF ## Installing **Using npm:** ```shell npm install @sophons/request ``` **Using bower:** ```shell bower install @sophons/request ``` **Using yarn:** ```shell yarn add @sophons/request ``` **Using cnpm:** ```shell cnpm install @sophons/request ``` ## Example [English Docs](docs/en.md) | [δΈ­ζ–‡ζ–‡ζ‘£](docs/cn.md) ## License [MIT](LICENSE)