Published on

Handling System Clipboard (Copy/Paste) Operations in Node.js


Ever wanted to access the system clipboard in your Node.js script?

With the help of clipboardy npm package, we can easily perform those operations.


npm install clipboardy


import clipboard from 'clipboardy';
clipboard.writeSync('Hello World');
clipboard.readSync(); // "Hello World"

Check out their docs for more snippets and methods to use clipboardy.

Happy copy-pasting texts!