Hugging Face
Models
Datasets
Spaces
Posts
Docs
Solutions
Pricing
Log In
Sign Up
Spaces:
huggingchat
/
chat-ui
like
1.04k
Running
App
Files
Files
Community
543
53e0136
chat-ui
/
src
/
lib
/
utils
/
share.ts
Mishig
Update share behaviour (#645)
c208e39
unverified
8 months ago
raw
Copy download link
history
blame
No virus
176 Bytes
export
async
function
share
(
url:
string
, title:
string
) {
if
(navigator.
share
) {
navigator.
share
({ url, title });
}
else
{
await
navigator.
clipboard
.
writeText
(url);
}
}