Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/waitingsong/fetch

Observable HTTP fetch API for browser and Node.js. Handle 302/303 redirect correctly on Node.js
https://github.com/waitingsong/fetch

fetch http typescript undici

Last synced: 2 months ago
JSON representation

Observable HTTP fetch API for browser and Node.js. Handle 302/303 redirect correctly on Node.js

Awesome Lists containing this project

README

        

# Node Fetch

[![GitHub tag](https://img.shields.io/github/tag/waitingsong/fetch.svg)]()
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://opensource.org/licenses/MIT)
[![](https://img.shields.io/badge/lang-TypeScript-blue.svg)]()
[![ci](https://github.com/waitingsong/fetch/workflows/ci/badge.svg)](https://github.com/waitingsong/fetch/actions?query=workflow%3A%22ci%22)
[![codecov](https://codecov.io/gh/waitingsong/fetch/branch/main/graph/badge.svg?token=v1yioFcT20)](https://codecov.io/gh/waitingsong/fetch)

## Note

ESM build only, requires `@midwayjs >= 3.16` and set `"type": "module"` in `packages.json`

## Install global deps for development
```sh
npm i -g c8 lerna madge rollup tsx zx
```

## 创建新项目

## Installation
```sh
npm i @waiting/fetch
// for Midway.js
npm i @mwcp/fetch
```

## Usage
- [fetch](https://github.com/waitingsong/fetch/tree/main/packages/fetch/test)
- [@mw-components/fetch](https://github.com/waitingsong/fetch/tree/main/packages/midway-component-fetch/test)

# 初始化依赖
npm install
```

## Packages

| Package | Version |
| --------------- | ---------------------- |
| [`fetch`] | [![main-svg]][main-ch] |
| [`@mwcp/fetch`] | [![mw-svg]][mw-ch] |

## Initialize and install dependencies

run it at first time and any time
```sh
npm run repo:init
```

## License
[MIT](LICENSE)


[`fetch`]: https://github.com/waitingsong/fetch/tree/main/packages/fetch
[main-svg]: https://img.shields.io/npm/v/@waiting/fetch.svg?maxAge=300
[main-ch]: https://github.com/waitingsong/fetch/tree/main/packages/fetch/CHANGELOG.md

[`@mwcp/fetch`]: https://github.com/waitingsong/fetch/tree/main/packages/midway-component-fetch
[mw-svg]: https://img.shields.io/npm/v/@mwcp/fetch.svg?maxAge=7200
[mw-ch]: https://github.com/waitingsong/fetch/tree/main/packages/midway-component-fetch/CHANGELOG.md