Clipboard
The Clipboard plugin provides access to the device clipboard, including copy and paste functionality.
#
InstallationIf you have not already setup Ionic Enterprise in your app, follow the one-time setup steps.
Next, install the plugin:
- Capacitor
- Cordova
#
Index#
Classes#
Classes#
Clipboardusage:
#
clear▸ clear(): Promise
<any
>
Clear the text stored in clipboard
Returns: Promise
<any
>
Returns a promise after the text has been cleaned
#
copy▸ copy(text: string
): Promise
<any
>
Copies the given text
Parameters:
Name | Type | Description |
---|---|---|
text | string | Text that gets copied on the system clipboard |
Returns: Promise
<any
>
Returns a promise after the text has been copied
#
paste▸ paste(): Promise
<any
>
Pastes the text stored in clipboard
Returns: Promise
<any
>
Returns a promise after the text has been pasted