Skip to content

Commit

Permalink
docs: Update types and documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
Ldoppea committed Jul 17, 2024
1 parent 192e4b4 commit c87fea9
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 9 deletions.
27 changes: 19 additions & 8 deletions docs/api/cozy-client/classes/StackLink.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ Transfers queries and mutations to a remote stack
| :------ | :------ | :------ |
| `[options]` | `Object` | Options |
| `[options].client` | `any` | - |
| `[options].platform` | `any` | - |
| `[options].stackClient` | `any` | - |

*Overrides*
Expand All @@ -30,17 +31,27 @@ Transfers queries and mutations to a remote stack

*Defined in*

[packages/cozy-client/src/StackLink.js:62](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L62)
[packages/cozy-client/src/StackLink.js:64](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L64)

## Properties

### isOnline

**isOnline**: `any`

*Defined in*

[packages/cozy-client/src/StackLink.js:72](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L72)

***

### stackClient

**stackClient**: `any`

*Defined in*

[packages/cozy-client/src/StackLink.js:69](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L69)
[packages/cozy-client/src/StackLink.js:71](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L71)

## Methods

Expand All @@ -62,7 +73,7 @@ Transfers queries and mutations to a remote stack

*Defined in*

[packages/cozy-client/src/StackLink.js:118](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L118)
[packages/cozy-client/src/StackLink.js:132](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L132)

***

Expand All @@ -82,7 +93,7 @@ Transfers queries and mutations to a remote stack

*Defined in*

[packages/cozy-client/src/StackLink.js:95](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L95)
[packages/cozy-client/src/StackLink.js:109](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L109)

***

Expand All @@ -107,7 +118,7 @@ Transfers queries and mutations to a remote stack

*Defined in*

[packages/cozy-client/src/StackLink.js:87](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L87)
[packages/cozy-client/src/StackLink.js:101](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L101)

***

Expand All @@ -127,7 +138,7 @@ Transfers queries and mutations to a remote stack

*Defined in*

[packages/cozy-client/src/StackLink.js:72](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L72)
[packages/cozy-client/src/StackLink.js:75](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L75)

***

Expand All @@ -153,7 +164,7 @@ Transfers queries and mutations to a remote stack

*Defined in*

[packages/cozy-client/src/StackLink.js:80](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L80)
[packages/cozy-client/src/StackLink.js:83](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L83)

***

Expand All @@ -167,4 +178,4 @@ Transfers queries and mutations to a remote stack

*Defined in*

[packages/cozy-client/src/StackLink.js:76](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L76)
[packages/cozy-client/src/StackLink.js:79](https://github.com/cozy/cozy-client/blob/master/packages/cozy-client/src/StackLink.js#L79)
5 changes: 4 additions & 1 deletion packages/cozy-client/types/StackLink.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,15 @@ export default class StackLink extends CozyLink {
* @param {object} [options] - Options
* @param {object} [options.stackClient] - A StackClient
* @param {object} [options.client] - A StackClient (deprecated)
* @param {import('cozy-pouch-link/dist/types').LinkPlatform} [options.platform] Platform specific adapters and methods
*/
constructor({ client, stackClient }?: {
constructor({ client, stackClient, platform }?: {
stackClient: object;
client: object;
platform: import('cozy-pouch-link/dist/types').LinkPlatform;
});
stackClient: any;
isOnline: any;
registerClient(client: any): void;
reset(): void;
/**
Expand Down
1 change: 1 addition & 0 deletions packages/cozy-client/types/utils.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ export function isQueryLoading(col: any): boolean;
export function hasQueryBeenLoaded(col: any): any;
export function isQueriesLoading(queriesResults: any): boolean;
export function hasQueriesBeenLoaded(queriesResults: any): boolean;
export function isReactNativeOfflineError(err: Error): boolean;
export type CancelablePromise = Promise<any>;
/**
* @typedef {Promise} CancelablePromise
Expand Down

0 comments on commit c87fea9

Please sign in to comment.