1
0
Fork 0
management/front/dkha-web-sz-main/node_modules/clipboardy/index.d.ts

38 lines
676 B
TypeScript
Raw Normal View History

2023-12-18 13:12:25 +08:00
/**
Write (copy) to the clipboard asynchronously.
@param text - The text to write to the clipboard.
*/
export function write(text: string): Promise<void>;
/**
Write (copy) to the clipboard synchronously.
2024-01-16 21:26:16 +08:00
Doesn't work in browsers.
2023-12-18 13:12:25 +08:00
@param text - The text to write to the clipboard.
@example
```
import * as clipboardy from 'clipboardy';
clipboardy.writeSync('🦄');
clipboardy.readSync();
//=> '🦄'
```
*/
export function writeSync(text: string): void;
/**
Read (paste) from the clipboard asynchronously.
*/
export function read(): Promise<string>;
/**
Read (paste) from the clipboard synchronously.
2024-01-16 21:26:16 +08:00
Doesn't work in browsers.
2023-12-18 13:12:25 +08:00
*/
export function readSync(): string;