Comparing version 1.2.8 to 1.3.0
{ | ||
"name": "autofetch", | ||
"version": "1.2.8", | ||
"version": "1.3.0", | ||
"description": "fetch for node", | ||
@@ -5,0 +5,0 @@ "main": "src/index.node.js", |
@@ -12,2 +12,8 @@ # autoFetch | ||
## Why Not `isomorphic-fetch` | ||
- More api for node env | ||
- Headers.keys | ||
- Headers.values | ||
- global baseHost,callback,headers,queries and url params | ||
## Usage | ||
@@ -32,2 +38,3 @@ ```js | ||
```` | ||
## Contribution | ||
PR and issue welcome |
"use strict"; | ||
const realFetch = require('isomorphic-fetch/fetch-npm-node.js'); | ||
global.Headers.prototype.keys = global.Headers.prototype.keys || | ||
function () { | ||
return Object.keys(this._headers || {}); | ||
}; | ||
global.Headers.prototype.values = global.Headers.prototype.values || | ||
function () { | ||
return Object.keys(this._headers || {}).map((key) => this._headers[k]); | ||
}; | ||
const { fetchDecorator } = require('./../dist/utils'); | ||
@@ -5,0 +16,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
37125
291
39