Added a way to secure the UI. Plus various bug fixes and quality of life updates
This commit is contained in:
@@ -79,10 +79,10 @@ export function useNestedState<T>(initialState: T): [T, (value: any, path?: stri
|
||||
const setValue = React.useCallback((value: any, path?: string) => {
|
||||
if (path === undefined) {
|
||||
setState(value);
|
||||
return
|
||||
return;
|
||||
}
|
||||
setState(prevState => setNestedValue(prevState, value, path));
|
||||
}, []);
|
||||
|
||||
return [state, setValue];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user