@emeryld/rrroutes-client 2.7.13 → 2.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +21 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +20 -7
- package/dist/index.mjs.map +1 -1
- package/dist/routesV3.client.types.d.ts +7 -1
- package/dist/sockets/socket.client.context.connection.d.ts +1 -1
- package/dist/sockets/socket.client.context.d.ts +1 -1
- package/package.json +1 -1
|
@@ -276,7 +276,13 @@ export type BuiltMutation<L extends AnyLeafLowProfile> = BuiltCommon<L> & {
|
|
|
276
276
|
fetch: MutationFetcher<L>;
|
|
277
277
|
};
|
|
278
278
|
/** Type-safe union that resolves to the correct built helper for a leaf. */
|
|
279
|
-
|
|
279
|
+
type BuiltLeafMetadata<L extends AnyLeafLowProfile> = {
|
|
280
|
+
metadata: {
|
|
281
|
+
leaf: L;
|
|
282
|
+
};
|
|
283
|
+
};
|
|
284
|
+
/** Type-safe union that resolves to the correct built helper for a leaf. */
|
|
285
|
+
export type BuiltForLeaf<L extends AnyLeafLowProfile> = (L['method'] extends 'get' ? L['cfg']['feed'] extends true ? BuiltInfinite<L> : BuiltQuery<L> : BuiltMutation<L>) & BuiltLeafMetadata<L>;
|
|
280
286
|
type LeafFromBuilt<B> = B extends BuiltForLeaf<infer L> ? L : AnyLeafLowProfile;
|
|
281
287
|
type SetDataUpdaterFromBuilt<B> = B extends {
|
|
282
288
|
setData: (updater: infer U, ...args: any[]) => any;
|
|
@@ -46,7 +46,7 @@ export type UseSocketEventArgs<T extends EventMap, K extends keyof T & string, C
|
|
|
46
46
|
}) => void;
|
|
47
47
|
enabled?: boolean;
|
|
48
48
|
onCleanup?: () => void;
|
|
49
|
-
messageDeduplication?: {
|
|
49
|
+
messageDeduplication?: false | {
|
|
50
50
|
ttlMs?: number;
|
|
51
51
|
key?: (payload: Payload<T, K>, meta?: {
|
|
52
52
|
envelope: ServerEnvelope<T[K]['__out']>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { buildSocketProvider } from './socket.client.context.provider';
|
|
2
2
|
export { useSocketClient } from './socket.client.context.client';
|
|
3
|
-
export {
|
|
3
|
+
export { type UseSocketConnectionDebugEvent, type UseSocketConnectionDebugOptions, type UseSocketConnectionArgs, type UseSocketEventArgs, type UseSocketRoomsArgs, } from './socket.client.context.connection';
|
|
4
4
|
export type { SocketProviderDebugEvent, SocketProviderDebugOptions, } from './socket.client.context.debug';
|