Files
new-phone-who-dis/phone/src/apps/contacts/hooks/useAlert.ts
T

9 lines
307 B
TypeScript

import { useRecoilState } from 'recoil';
import { IContactAlert } from '../../../common/typings/contact';
import { contactsState } from './state';
export const useContactAlert = (): IContactAlert => {
const [alert, setAlert] = useRecoilState(contactsState.contactAlert);
return { alert, setAlert };
};