* Wip refactoring view * Post merge conflicts * Fix review * Add create view capability * Fix create object missing view * Fix tests
17 lines
507 B
TypeScript
17 lines
507 B
TypeScript
import { useEffect } from 'react';
|
|
import { useSetRecoilState } from 'recoil';
|
|
|
|
import { COMMAND_MENU_COMMANDS } from '@/command-menu/constants/CommandMenuCommands';
|
|
import { commandMenuCommandsState } from '@/command-menu/states/commandMenuCommandsState';
|
|
|
|
export const CommandMenuEffect = () => {
|
|
const setCommands = useSetRecoilState(commandMenuCommandsState);
|
|
|
|
const commands = COMMAND_MENU_COMMANDS;
|
|
useEffect(() => {
|
|
setCommands(commands);
|
|
}, [commands, setCommands]);
|
|
|
|
return <></>;
|
|
};
|