mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-06-03 14:36:02 +08:00
[relay] ConcreteFragment should have been FragmentReference.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
// tslint:disable:interface-over-type-literal
|
||||
|
||||
import * as React from "react";
|
||||
import { Environment, Network, RecordSource, Store, ConnectionHandler, ConcreteFragment } from "relay-runtime";
|
||||
import { Environment, Network, RecordSource, Store, ConnectionHandler, FragmentReference } from "relay-runtime";
|
||||
|
||||
import {
|
||||
graphql,
|
||||
@@ -62,7 +62,7 @@ type StoryLike = (storyID: string) => void;
|
||||
|
||||
// Artifact produced by relay-compiler-language-typescript
|
||||
const enum _Story_story$ref {}
|
||||
type Story_story$ref = _Story_story$ref & ConcreteFragment;
|
||||
type Story_story$ref = _Story_story$ref & FragmentReference;
|
||||
type Story_story = {
|
||||
readonly id: string;
|
||||
readonly text: string;
|
||||
@@ -145,7 +145,7 @@ const Story = (() => {
|
||||
|
||||
// Artifact produced by relay-compiler-language-typescript
|
||||
const enum _FeedStories_feed$ref {}
|
||||
type FeedStories_feed$ref = _FeedStories_feed$ref & ConcreteFragment;
|
||||
type FeedStories_feed$ref = _FeedStories_feed$ref & FragmentReference;
|
||||
type FeedStories_feed = {
|
||||
readonly edges: ReadonlyArray<{
|
||||
readonly node: {
|
||||
@@ -206,7 +206,7 @@ const Feed = (() => {
|
||||
|
||||
// Artifact produced by relay-compiler-language-typescript
|
||||
const enum _UserFeed_user$ref {}
|
||||
type UserFeed_user$ref = _UserFeed_user$ref & ConcreteFragment;
|
||||
type UserFeed_user$ref = _UserFeed_user$ref & FragmentReference;
|
||||
type UserFeed_user = {
|
||||
readonly feed: {
|
||||
readonly pageInfo: {
|
||||
|
||||
8
types/relay-runtime/index.d.ts
vendored
8
types/relay-runtime/index.d.ts
vendored
@@ -38,12 +38,14 @@ export type RelayContainer = any;
|
||||
|
||||
// File: https://github.com/facebook/relay/blob/fe0e70f10bbcba1fff89911313ea69f24569464b/packages/relay-runtime/util/RelayConcreteNode.js
|
||||
// Using enum here to create a distinct types.
|
||||
export const enum ConcreteFragment {}
|
||||
export const enum ConcreteRequest {}
|
||||
export const enum ConcreteBatchRequest {}
|
||||
export type ConcreteFragment = any;
|
||||
export type ConcreteRequest = any;
|
||||
export type ConcreteBatchRequest = any;
|
||||
|
||||
export type RequestNode = ConcreteRequest | ConcreteBatchRequest;
|
||||
|
||||
export const enum FragmentReference {}
|
||||
|
||||
// ~~~~~~~~~~~~~~~~~~~~~
|
||||
// RelayQL
|
||||
// ~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Reference in New Issue
Block a user