New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@types/react-relay

Package Overview
Dependencies
Maintainers
1
Versions
92
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/react-relay - npm Package Compare versions

Comparing version 11.0.1 to 11.0.2

20

react-relay/legacy.d.ts

@@ -60,4 +60,4 @@ import * as React from 'react';

{
cacheConfig?: CacheConfig | null;
fetchPolicy?: FetchPolicy;
cacheConfig?: CacheConfig | null | undefined;
fetchPolicy?: FetchPolicy | undefined;
} & QueryRendererProps<TOperation>

@@ -83,3 +83,3 @@ > { }

export type RelayProps<Props> = ContainerProps<Props>; // TODO: validate this
export type Container<Props> = React.ComponentType<ContainerProps<Props> & { componentRef?: (ref: any) => void }>;
export type Container<Props> = React.ComponentType<ContainerProps<Props> & { componentRef?: ((ref: any) => void) | undefined }>;

@@ -100,3 +100,3 @@ // TODO: validate the bellow three

export function createFragmentContainer<Props>(
Component: React.ComponentType<Props & { relay?: RelayProp }>,
Component: React.ComponentType<Props & { relay?: RelayProp | undefined }>,
fragmentSpec: Record<string, GraphQLTaggedNode>,

@@ -132,8 +132,8 @@ ): Container<Props>;

export interface ConnectionConfig<Props = object> {
direction?: 'backward' | 'forward';
getConnectionFromProps?: (props: Props) => ConnectionData | null | undefined;
getFragmentVariables?: (prevVars: Variables, totalCount: number) => Variables;
direction?: 'backward' | 'forward' | undefined;
getConnectionFromProps?: ((props: Props) => ConnectionData | null | undefined) | undefined;
getFragmentVariables?: ((prevVars: Variables, totalCount: number) => Variables) | undefined;
getVariables: (
props: Props,
paginationInfo: { count: number; cursor?: string | null },
paginationInfo: { count: number; cursor?: string | null | undefined },
fragmentVariables: Variables,

@@ -145,4 +145,4 @@ ) => Variables;

interface ConnectionData {
edges?: ReadonlyArray<any> | null;
pageInfo?: Partial<PageInfo> | null;
edges?: ReadonlyArray<any> | null | undefined;
pageInfo?: Partial<PageInfo> | null | undefined;
}
{
"name": "@types/react-relay",
"version": "11.0.1",
"version": "11.0.2",
"description": "TypeScript definitions for react-relay",
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-relay",
"license": "MIT",

@@ -35,4 +36,4 @@ "contributors": [

},
"typesPublisherContentHash": "50cfbe03a07a8c209a190b070831dbe57cd3029f9aa9ca876d89f01f62ffaae1",
"typesPublisherContentHash": "0a16d0581dd50d13bc398b86eb44a115bca7e742ba57b7acd3835962581b14c3",
"typeScriptVersion": "3.7"
}

@@ -31,4 +31,4 @@ import * as React from 'react';

export interface RefetchOptions {
force?: boolean;
fetchPolicy?: 'store-or-network' | 'network-only';
force?: boolean | undefined;
fetchPolicy?: 'store-or-network' | 'network-only' | undefined;
}

@@ -35,0 +35,0 @@

@@ -11,3 +11,3 @@ # Installation

### Additional Details
* Last updated: Fri, 02 Apr 2021 00:31:10 GMT
* Last updated: Wed, 07 Jul 2021 17:33:55 GMT
* Dependencies: [@types/relay-runtime](https://npmjs.com/package/@types/relay-runtime), [@types/react](https://npmjs.com/package/@types/react)

@@ -14,0 +14,0 @@ * Global values: none

@@ -28,11 +28,11 @@ import { ComponentType } from 'react';

export type PreloadOptions = Readonly<{
fetchKey?: string | number;
fetchPolicy?: PreloadFetchPolicy | null;
networkCacheConfig?: CacheConfig | null;
fetchKey?: string | number | undefined;
fetchPolicy?: PreloadFetchPolicy | null | undefined;
networkCacheConfig?: CacheConfig | null | undefined;
}>;
export type LoadQueryOptions = Readonly<{
fetchPolicy?: PreloadFetchPolicy | null;
networkCacheConfig?: CacheConfig | null;
onQueryAstLoadTimeout?: (() => void) | null;
fetchPolicy?: PreloadFetchPolicy | null | undefined;
networkCacheConfig?: CacheConfig | null | undefined;
onQueryAstLoadTimeout?: (() => void) | null | undefined;
}>;

@@ -56,9 +56,9 @@

environment: IEnvironment;
environmentProviderOptions?: TEnvironmentProviderOptions | null;
environmentProviderOptions?: TEnvironmentProviderOptions | null | undefined;
fetchKey: string | number;
fetchPolicy: PreloadFetchPolicy;
networkCacheConfig?: CacheConfig | null;
id?: string | null;
networkCacheConfig?: CacheConfig | null | undefined;
id?: string | null | undefined;
name: string;
source?: Observable<GraphQLResponse> | null;
source?: Observable<GraphQLResponse> | null | undefined;
variables: VariablesOf<TQuery>;

@@ -70,5 +70,5 @@ dispose: DisposeFn;

export type PreloadQueryStatus = Readonly<{
cacheConfig?: CacheConfig | null;
cacheConfig?: CacheConfig | null | undefined;
source: 'cache' | 'network';
fetchTime?: number | null;
fetchTime?: number | null | undefined;
}>;

@@ -164,5 +164,5 @@

> extends Readonly<{
entryPoints?: ThinNestedEntryPointParamsObject<TPreloadedEntryPoints>;
extraProps?: TExtraProps;
queries?: ThinQueryParamsObject<TPreloadedQueries>;
entryPoints?: ThinNestedEntryPointParamsObject<TPreloadedEntryPoints> | undefined;
extraProps?: TExtraProps | undefined;
queries?: ThinQueryParamsObject<TPreloadedQueries> | undefined;
}> {}

@@ -223,4 +223,4 @@

*/
options?: PreloadOptions | null;
environmentProviderOptions?: TEnvironmentProviderOptions | null;
options?: PreloadOptions | null | undefined;
environmentProviderOptions?: TEnvironmentProviderOptions | null | undefined;
}> {}

@@ -227,0 +227,0 @@

@@ -9,3 +9,3 @@ /*

export type KeyType<TData = unknown> = Readonly<{
' $data'?: TData;
' $data'?: TData | undefined;
' $fragmentRefs': FragmentReference;

@@ -12,0 +12,0 @@ }>;

@@ -73,4 +73,4 @@ import { ComponentType, ElementType, ReactNode } from 'react';

export type MatchPointer = Readonly<{
__fragmentPropName?: string | null;
__module_component?: unknown;
__fragmentPropName?: string | null | undefined;
__module_component?: unknown | undefined;
' $fragmentRefs': unknown;

@@ -80,6 +80,6 @@ }>;

export type MatchContainerProps<TProps = {}, TFallback = ReactNode> = Readonly<{
fallback?: TFallback | null;
fallback?: TFallback | null | undefined;
loader: (module: unknown) => ComponentType<TProps>;
match?: MatchPointer | TypenameOnlyPointer | null;
props?: TProps;
match?: MatchPointer | TypenameOnlyPointer | null | undefined;
props?: TProps | undefined;
}>;

@@ -86,0 +86,0 @@

@@ -7,7 +7,7 @@ import { CacheConfig, FetchPolicy, GraphQLTaggedNode, OperationType, RenderPolicy, VariablesOf } from 'relay-runtime';

options?: {
fetchKey?: string | number;
fetchPolicy?: FetchPolicy;
networkCacheConfig?: CacheConfig;
UNSTABLE_renderPolicy?: RenderPolicy;
fetchKey?: string | number | undefined;
fetchPolicy?: FetchPolicy | undefined;
networkCacheConfig?: CacheConfig | undefined;
UNSTABLE_renderPolicy?: RenderPolicy | undefined;
},
): TQuery['response'];

@@ -18,4 +18,4 @@ import {

options?: {
onComplete?: (arg: Error | null) => void;
UNSTABLE_extraVariables?: Partial<VariablesOf<TQuery>>;
onComplete?: ((arg: Error | null) => void) | undefined;
UNSTABLE_extraVariables?: Partial<VariablesOf<TQuery>> | undefined;
},

@@ -31,3 +31,3 @@ ) => Disposable;

connectionPathInFragmentData: ReadonlyArray<string | number>;
identifierField?: string | null;
identifierField?: string | null | undefined;
paginationRequest: ConcreteRequest;

@@ -51,4 +51,4 @@ paginationMetadata: ReaderPaginationMetadata;

): {
cursor?: string | null;
cursor?: string | null | undefined;
hasMore: boolean;
};

@@ -16,10 +16,10 @@ import {

variables: VariablesOf<TMutation>;
updater?: SelectorStoreUpdater<TMutation['response']> | null;
uploadables?: UploadableMap;
optimisticUpdater?: SelectorStoreUpdater<TMutation['response']> | null;
optimisticResponse?: TMutation['rawResponse'];
configs?: DeclarativeMutationConfig[];
onError?: (error: Error) => void | null;
onCompleted?: (response: TMutation['response'], errors: PayloadError[] | null) => void | null;
onUnsubscribe?: () => void | null;
updater?: SelectorStoreUpdater<TMutation['response']> | null | undefined;
uploadables?: UploadableMap | undefined;
optimisticUpdater?: SelectorStoreUpdater<TMutation['response']> | null | undefined;
optimisticResponse?: TMutation['rawResponse'] | undefined;
configs?: DeclarativeMutationConfig[] | undefined;
onError?: ((error: Error) => void | null) | undefined;
onCompleted?: ((response: TMutation['response'], errors: PayloadError[] | null) => void | null) | undefined;
onUnsubscribe?: (() => void | null) | undefined;
}

@@ -26,0 +26,0 @@

@@ -9,4 +9,4 @@ import { GraphQLTaggedNode, OperationType, RenderPolicy } from 'relay-runtime';

options?: {
UNSTABLE_renderPolicy?: RenderPolicy;
UNSTABLE_renderPolicy?: RenderPolicy | undefined;
},
): TQuery['response'];

@@ -11,3 +11,3 @@ import { DisposeFn, GraphQLTaggedNode, OperationType, VariablesOf, IEnvironment } from 'relay-runtime';

export type UseQueryLoaderLoadQueryOptions = LoadQueryOptions & Readonly<{
__environment?: IEnvironment | null,
__environment?: IEnvironment | null | undefined,
}>;

@@ -14,0 +14,0 @@

@@ -63,9 +63,9 @@ import {

export interface Options {
fetchPolicy?: FetchPolicy;
onComplete?: (arg: Error | null) => void;
UNSTABLE_renderPolicy?: RenderPolicy;
fetchPolicy?: FetchPolicy | undefined;
onComplete?: ((arg: Error | null) => void) | undefined;
UNSTABLE_renderPolicy?: RenderPolicy | undefined;
}
export interface InternalOptions extends Options {
__environment?: IEnvironment;
__environment?: IEnvironment | undefined;
}

@@ -82,16 +82,16 @@

refetchVariables: Variables;
fetchPolicy?: FetchPolicy;
renderPolicy?: RenderPolicy;
onComplete?: (args: Error | null) => void;
environment?: IEnvironment | null;
fetchPolicy?: FetchPolicy | undefined;
renderPolicy?: RenderPolicy | undefined;
onComplete?: ((args: Error | null) => void) | undefined;
environment?: IEnvironment | null | undefined;
};
export interface RefetchState {
fetchPolicy?: FetchPolicy;
renderPolicy?: RenderPolicy;
fetchPolicy?: FetchPolicy | undefined;
renderPolicy?: RenderPolicy | undefined;
mirroredEnvironment: IEnvironment;
mirroredFragmentIdentifier: string;
onComplete?: (arg: Error | null) => void;
refetchEnvironment?: IEnvironment | null;
refetchVariables?: Variables | null;
onComplete?: ((arg: Error | null) => void) | undefined;
refetchEnvironment?: IEnvironment | null | undefined;
refetchVariables?: Variables | null | undefined;
refetchGeneration: number;

@@ -98,0 +98,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc