import { useEffect } from 'react'; import { useDispatch } from 'react-redux'; import { METADATA } from '../constants'; import { PageType, setPageType, setPostTitle } from '../state/navigation'; import { IPost } from '../types/cms'; import { Article } from '../components/article/Article'; import CustomHead from './CustomHead'; interface Props { post: IPost; } // Parallax on bg as mouse moves export default function BlogPost(props: Props) { const { post } = props; const dispatch = useDispatch(); useEffect(() => { if (post) { dispatch(setPageType(PageType.POST)); dispatch(setPostTitle(post.title)); } }, []); return ( <>
); }