@types/relay-runtime
Advanced tools
Comparing version 8.0.8 to 8.0.9
import { DeclarativeMutationConfig } from '../mutations/RelayDeclarativeMutationConfig'; | ||
import { GraphQLTaggedNode } from '../query/RelayModernGraphQLTag'; | ||
import { Variables, Disposable } from '../util/RelayRuntimeTypes'; | ||
import { Variables, Disposable, OperationType } from '../util/RelayRuntimeTypes'; | ||
import { SelectorStoreUpdater, Environment } from '../store/RelayStoreTypes'; | ||
export interface GraphQLSubscriptionConfig<TSubscriptionPayload> { | ||
export interface GraphQLSubscriptionConfig<TSubscription extends OperationType> { | ||
configs?: ReadonlyArray<DeclarativeMutationConfig>; | ||
@@ -12,10 +12,10 @@ subscription: GraphQLTaggedNode; | ||
onError?: (error: Error) => void; | ||
onNext?: (response: TSubscriptionPayload | null | undefined) => void; | ||
updater?: SelectorStoreUpdater<TSubscriptionPayload>; | ||
onNext?: (response: TSubscription['response'] | null | undefined) => void; | ||
updater?: SelectorStoreUpdater<TSubscription['response']>; | ||
} | ||
export function requestSubscription<TSubscriptionPayload>( | ||
export function requestSubscription<TSubscription extends OperationType = OperationType>( | ||
environment: Environment, | ||
// tslint:disable-next-line no-unnecessary-generics | ||
config: GraphQLSubscriptionConfig<TSubscriptionPayload>, | ||
config: GraphQLSubscriptionConfig<TSubscription>, | ||
): Disposable; |
{ | ||
"name": "@types/relay-runtime", | ||
"version": "8.0.8", | ||
"version": "8.0.9", | ||
"description": "TypeScript definitions for relay-runtime", | ||
@@ -47,4 +47,4 @@ "license": "MIT", | ||
"dependencies": {}, | ||
"typesPublisherContentHash": "f95019749b773dce0da9977466fd38da1b15a772abad26c73b55f011570bc9ce", | ||
"typesPublisherContentHash": "df7d58dfe7531d8d3ec6fdad30d0cd94ce1096334f043e52cc721180f2bd76d0", | ||
"typeScriptVersion": "3.0" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
### Additional Details | ||
* Last updated: Tue, 07 Apr 2020 10:13:52 GMT | ||
* Last updated: Tue, 28 Apr 2020 13:13:41 GMT | ||
* Dependencies: none | ||
@@ -14,0 +14,0 @@ * Global values: none |
Sorry, the diff of this file is not supported yet
100202