@shopify/react-network
Version:
A collection of components that allow you to set common HTTP headers from within your React application.
7 lines (6 loc) • 442 B
TypeScript
import { CspDirective, StatusCode } from '@shopify/network';
import { NetworkManager } from './manager';
export declare function useNetworkEffect(perform: (network: NetworkManager) => void): void;
export declare function useCspDirective(directive: CspDirective, source: string | string[] | boolean): void;
export declare function useStatus(code: StatusCode): void;
export declare function useRedirect(url: string, status?: StatusCode): void;