Răsfoiți Sursa

Fixing sharing shared app link

bodicsek 6 ani în urmă
părinte
comite
70e0a90bbb
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      src/components/ActionBar.tsx

+ 1 - 1
src/components/ActionBar.tsx

@@ -14,7 +14,7 @@ const copyToClipboard = (text: string) => navigator.clipboard.writeText(text)
     (err) => console.error('Async: Could not copy text: ', err)
   );
 
-const shareApp = (state: RootState) => copyToClipboard(`${window.location.href}?state=${encodeURIComponent(JSON.stringify(state))}`);
+const shareApp = (state: RootState) => copyToClipboard(`${window.location.origin}${window.location.pathname}?state=${encodeURIComponent(JSON.stringify(state))}`);
 
 export interface Props {
   fullPath: string;