cogsbox-state 0.5.61 → 0.5.63
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/CogsState.d.ts +3 -6
- package/dist/CogsState.jsx +446 -446
- package/dist/CogsState.jsx.map +1 -1
- package/package.json +1 -1
package/dist/CogsState.d.ts
CHANGED
|
@@ -191,11 +191,8 @@ export type OptionsType<T extends unknown = unknown> = {
|
|
|
191
191
|
reactiveDeps?: (state: T) => any[] | true;
|
|
192
192
|
reactiveType?: ReactivityType[] | ReactivityType;
|
|
193
193
|
syncUpdate?: Partial<UpdateTypeDetail>;
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
initialState: T;
|
|
197
|
-
dependencies?: any[];
|
|
198
|
-
};
|
|
194
|
+
initialState?: T;
|
|
195
|
+
dependencies?: any[];
|
|
199
196
|
};
|
|
200
197
|
export type ServerSyncType<T> = {
|
|
201
198
|
testKey?: string;
|
|
@@ -277,7 +274,7 @@ type LocalStorageData<T> = {
|
|
|
277
274
|
baseServerState?: T;
|
|
278
275
|
};
|
|
279
276
|
export declare const notifyComponent: (stateKey: string, componentId: string) => void;
|
|
280
|
-
export declare function useCogsStateFn<TStateObject extends unknown>(stateObject: TStateObject, { stateKey, serverSync, localStorage, formElements, middleware, reactiveDeps, reactiveType, componentId,
|
|
277
|
+
export declare function useCogsStateFn<TStateObject extends unknown>(stateObject: TStateObject, { stateKey, serverSync, localStorage, formElements, middleware, reactiveDeps, reactiveType, componentId, initialState, syncUpdate, dependencies, }?: {
|
|
281
278
|
stateKey?: string;
|
|
282
279
|
componentId?: string;
|
|
283
280
|
} & OptionsType<TStateObject>): [TStateObject, StateObject<TStateObject>];
|