ShareSheet
Share text, links and files
Takes a string or an array of them; anything that parses as a URL is shared as a link. Returns true if something was chosen. In-app only; check isAvailable.
Properties
isAvailableBooleanFalse in a widget.
Methods
ShareSheet.present(items)BooleanShares a string or an array of strings.
- items Any required
A string, or an array of strings. A string that parses as a URL is shared as a link, so the sheet offers Open in Safari rather than treating it as prose.
returns true when the user completed a share, false when they dismissed the sheet.
Examples
Sharing a result
ShareSheet.present(["Today: 4,213 steps", "https://example.com"]);