import { usePathname } from 'next/navigation' import React, { useEffect, useState } from 'react' import { LinkedinShareButton, LinkedinIcon, TwitterShareButton, XIcon, } from 'react-share' const SocialShareButton = () => { const [url, setUrl] = useState('') const pathname = usePathname() useEffect(() => { if (window !== undefined) { setUrl(window.location.origin + pathname) } }, [pathname]) return (