quivr/frontend/lib/hooks/useToast.ts

11 lines
232 B
TypeScript
Raw Normal View History

import { useContext } from "react";
import { ToastContext } from "../../app/components/ui/Toast/domain/ToastContext";
export const useToast = () => {
const { publish } = useContext(ToastContext);
return {
publish,
};
};