Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

my-fetch-plus

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

my-fetch-plus

enhance Fetch API experience

  • 0.0.5
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

MyFetchPlus

一个fetch的现代化封装

https://fetch.plus

基本功能

  • 以es6 class封装fetch
  • 自动格式化URL QueryString
  • 根据responseType自动格式化Data
  • 超时取消请求
  • 返回值遵循error first 原则

基本使用

安装

npm i my-fetch-plus --save

or

yarn add my-fetch-plus

引入

可以通过import或require引入

import FetchPlus from 'my-fetch-plus'
const http = new FetchPlus()
http.get('xxxx')

TODO

  • 基本请求封装
  • 只发送简单请求
  • 单元测试
  • 失败重试

参考资料

Keywords

FAQs

Package last updated on 20 Oct 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc