fetch-detector

1.0.1 • Public • Published

Fetch Detector

有些浏览器虽然支持 Fetch API 但不完整,如 Chrome 45 和 Firefox 33 版本 response 中的中文会乱码2。本库的作用是只在 Chrome >= 46,Firefox >= 39 时才开启原生 Fetch,否则使用 XHR polyfill。

Install

npm install 'fetch-detector'

Usage

一定要与 fetch-ie8 一起使用, 并且放到 fetch-ie8 前引用。

import 'fetch-detector'
import 'fetch-ie8'

License

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.1
    65
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.1
    65
  • 1.0.0
    1

Package Sidebar

Install

npm i fetch-detector

Weekly Downloads

66

Version

1.0.1

License

MIT

Last publish

Collaborators

  • camsong