a tool for shared writing and social publishing
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

strip leading / char from pathname in collabLink to prevent double slash in url

+2 -1
+2 -1
components/ShareOptions/index.tsx
··· 35 35 let publishLink = usePublishLink(); 36 36 let [collabLink, setCollabLink] = useState<null | string>(null); 37 37 useEffect(() => { 38 - setCollabLink(window.location.pathname); 38 + // strip leading '/' character from pathname 39 + setCollabLink(window.location.pathname.slice(1)); 39 40 }, []); 40 41 41 42 let smoker = useSmoker();