Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
mayank1513 committed Feb 21, 2024
1 parent 84b322e commit ec56996
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion lib/r18gs/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
import useRGS from "./use-rgs";

export default useRGS;
export default useRGS;
5 changes: 1 addition & 4 deletions lib/r18gs/src/use-rgs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,7 @@ globalThis.rgs = {};
* const [state, setState] = useRGS<number>("counter", 1);
* ```
*/
export default function useRGS<T>(
key: string,
value?: T,
): [T, (val: SetterArgType<T>) => void] {
export default function useRGS<T>(key: string, value?: T): [T, (val: SetterArgType<T>) => void] {
const setRGState = useCallback(
(val: SetterArgType<T>) => {
const rgs = globalThis.rgs[key] as React18GlobalStore;
Expand Down

0 comments on commit ec56996

Please sign in to comment.