@shopify/react-network
Advanced tools
Comparing version 3.1.4 to 3.1.5
@@ -8,4 +8,10 @@ # Changelog | ||
## [Unreleased] | ||
<!-- ## [Unreleased] --> | ||
## [3.1.1] - 2019-08-20 | ||
## Fixed | ||
- `useRequestHeader` now works as documented when instantiated with `ctx.headers` [#888](https://github.com/Shopify/quilt/pull/888) | ||
## [3.1.0] - 2019-06-14 | ||
@@ -12,0 +18,0 @@ |
@@ -5,7 +5,4 @@ import { StatusCode, CspDirective } from '@shopify/network'; | ||
export declare const EFFECT_ID: unique symbol; | ||
interface Headers { | ||
get(header: string): string | undefined; | ||
} | ||
interface Options { | ||
headers?: Headers; | ||
headers?: Record<string, string>; | ||
} | ||
@@ -12,0 +9,0 @@ export declare class NetworkManager { |
@@ -33,3 +33,3 @@ "use strict"; | ||
NetworkManager.prototype.getHeader = function (header) { | ||
return this.requestHeaders && this.requestHeaders.get(header); | ||
return this.requestHeaders && this.requestHeaders[header]; | ||
}; | ||
@@ -36,0 +36,0 @@ NetworkManager.prototype.setHeader = function (header, value) { |
{ | ||
"name": "@shopify/react-network", | ||
"version": "3.1.4", | ||
"version": "3.1.5", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "description": "A collection of components that allow you to set common HTTP headers from within your React application.", |
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
32971
689