0.1.0 • Published 8 years ago

fetch-for-babel-umd v0.1.0

Weekly downloads
1
License
Unlicense
Repository
github
Last release
8 years ago

fetch for babel

Purpose

Use this module when creating ES2015 modules that will be exported to UMD via Bower.

Example

import 'fetch-for-babel'
// Adds "fetch" to global scope in Node, does nothing in browser, leaving native fetch alone.
// Browsers without native fetch will require a polyfill.

fetch('https://example.com').then(response => {
  if (response.ok) {
    // do something
  }
}, error => {
  console.error(error)
})
0.1.0

8 years ago