share
Die Übersetzung dieser Seite fehlt oder ist veraltet, daher wird sie auf Englisch angezeigt. Auf Englisch lesen
Open the platform share sheet for text, URLs or a file. Use it when the user chooses where content should go.
Share a message or file
import { share } from 'kuito';
const result = await share(
{ message: 'Severance', url: 'https://www.tvmaze.com/shows/44933', title: 'A show' },
{ dialogTitle: 'Share a show', subject: 'Watch this' },
);
if (result.action === 'shared') console.log('shared with', result.activityType);Behavior and limits
Await the result and treat dismissal as normal. Share local media by its supported file URI and keep the file available until the share action completes. Available destinations and activity results differ by platform; do not assume the receiver actually consumed the content.
Continue
Read File system for the related workflow. The API reference lists every method, option, event and return type.
Referenz
Signaturen
(content: ShareContent, options?: ShareOptions): Promise<ShareResult>Parameter
| Name | Typ | Erforderlich | Beschreibung |
|---|---|---|---|
content | ShareContent | Ja | — |
options | ShareOptions | Nein | — Standard: {} |
Rückgabe
Promise<SpecShareResult>
Generiert aus den öffentlichen TypeScript-Deklarationen: Signaturen, Props und Standardwerte stammen aus der geprüften Quelle, Beschreibungen aus deren JSDoc. Kein Standardwert ist erfunden.