reactjrx 1.48.0 → 1.50.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.
|
@@ -10,7 +10,7 @@ type WithOptionalKey<V> = V extends undefined ? {
|
|
|
10
10
|
} : {
|
|
11
11
|
key: V;
|
|
12
12
|
};
|
|
13
|
-
type Config<R = undefined, K = undefined> = WithOptionalKey<K> & WithOptionalDefault<R>;
|
|
13
|
+
export type Config<R = undefined, K = undefined> = WithOptionalKey<K> & WithOptionalDefault<R>;
|
|
14
14
|
type setValue<S> = (stateOrUpdater: typeof SIGNAL_RESET | S | ((prev: S) => S)) => void;
|
|
15
15
|
export interface Signal<S = undefined, R = undefined, K = undefined> {
|
|
16
16
|
setValue: setValue<S>;
|
|
@@ -18,5 +18,6 @@ export interface Signal<S = undefined, R = undefined, K = undefined> {
|
|
|
18
18
|
config: Config<S, K>;
|
|
19
19
|
subject: Observable<S>;
|
|
20
20
|
}
|
|
21
|
-
export declare function signal<T = undefined
|
|
21
|
+
export declare function signal<T = undefined>(config: Config<T, string>): Signal<T, T, string>;
|
|
22
|
+
export declare function signal<T = undefined>(config: Config<T, undefined>): Signal<T, T>;
|
|
22
23
|
export {};
|