Skip to content

Commit f0c81f3

Browse files
committed
Fixed typings
1 parent 553a05c commit f0c81f3

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

common/api-review/data-connect.api.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,9 @@ export function executeMutation<Data, Variables>(mutationRef: MutationRef<Data,
8383
// @public
8484
export function executeQuery<Data, Variables>(queryRef: QueryRef<Data, Variables>): QueryPromise<Data, Variables>;
8585

86+
// @public (undocumented)
87+
export const fdcSymbol: unique symbol;
88+
8689
// @public
8790
export function getDataConnect(options: ConnectorConfig): DataConnect;
8891

@@ -126,7 +129,7 @@ export type OnResultSubscription<Data, Variables> = (res: QueryResult<Data, Vari
126129
// @public (undocumented)
127130
export interface OperationRef<Data, Variables> {
128131
// (undocumented)
129-
__keepForTypingsOnly?: Data;
132+
[fdcSymbol]?: Data;
130133
// (undocumented)
131134
dataConnect: DataConnect;
132135
// (undocumented)

packages/data-connect/src/api/Reference.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,14 @@ export interface OpResult<Data> {
3030
fetchTime: string;
3131
}
3232

33-
const fdcSymbol = Symbol();
33+
export const fdcSymbol = Symbol();
3434

3535
export interface OperationRef<Data, Variables> {
3636
name: string;
3737
variables: Variables;
3838
refType: ReferenceType;
3939
dataConnect: DataConnect;
40-
[fdcSymbol]: Data; // Never used, just here to ensure that the Data type doesn't get erased.
40+
[fdcSymbol]?: Data; // Never used, just here to ensure that the Data type doesn't get erased.
4141
}
4242

4343
export interface DataConnectResult<Data, Variables> extends OpResult<Data> {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"extends": "../../config/api-extractor.json",
33
// Point it to your entry point d.ts file.
4-
"mainEntryPointFilePath": "<projectFolder>/dist/rules-unit-testing/index.d.ts"
4+
"mainEntryPointFilePath": "<projectFolder>/dist/index.d.ts"
55
}

0 commit comments

Comments
 (0)