chat-ui / src /lib /utils /share.ts
Mishig
Update share behaviour (#645)
c208e39 unverified
raw
history blame
176 Bytes
export async function share(url: string, title: string) {
if (navigator.share) {
navigator.share({ url, title });
} else {
await navigator.clipboard.writeText(url);
}
}