Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement the canShare() and share() methods for Navigator #2514

Closed
sinking-point opened this issue Mar 31, 2021 · 0 comments · Fixed by #3882
Closed

Implement the canShare() and share() methods for Navigator #2514

sinking-point opened this issue Mar 31, 2021 · 0 comments · Fixed by #3882

Comments

@sinking-point
Copy link
Contributor

Motivation

I would like to be able to invoke the native sharing interface when available in a project I'm working on, so that users can share the link to any platform they like, rather than only ones I've specifically added share links for.

Proposed Solution

Implement Navigator.canShare() and Navigator.share() in web_sys::Navigator.

Alternatives

The only alternative I can think of would be interfacing with JavaScript directly in my code. The proposed solution is clearly superior because it makes things much more convenient for anyone who wants to use the share API.

Does anyone know how to do this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant