clipboardy

WebJar for clipboardy

License

License

MIT
Categories

Categories

CLI User Interface
GroupId

GroupId

org.webjars.npm
ArtifactId

ArtifactId

clipboardy
Last Version

Last Version

1.2.2
Release Date

Release Date

Type

Type

jar
Description

Description

clipboardy
WebJar for clipboardy
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/sindresorhus/clipboardy

Download clipboardy

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.npm/clipboardy/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>clipboardy</artifactId>
    <version>1.2.2</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/clipboardy/
implementation 'org.webjars.npm:clipboardy:1.2.2'
// https://jarcasting.com/artifacts/org.webjars.npm/clipboardy/
implementation ("org.webjars.npm:clipboardy:1.2.2")
'org.webjars.npm:clipboardy:jar:1.2.2'
<dependency org="org.webjars.npm" name="clipboardy" rev="1.2.2">
  <artifact name="clipboardy" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='clipboardy', version='1.2.2')
)
libraryDependencies += "org.webjars.npm" % "clipboardy" % "1.2.2"
[org.webjars.npm/clipboardy "1.2.2"]

Dependencies

compile (2)

Group / Artifact Type Version
org.webjars.npm » arch jar [2.1.0,3)
org.webjars.npm : execa jar [0.8.0,0.9)

Project Modules

There are no modules declared in this project.

clipboardy

Access the system clipboard (copy/paste)

Cross-platform. Supports: macOS, Windows, Linux, OpenBSD, FreeBSD, Android with Termux, and modern browsers.

Install

$ npm install clipboardy

Usage

const clipboardy = require('clipboardy');

clipboardy.writeSync('🦄');

clipboardy.readSync();
//=> '🦄'

API

clipboardy

.write(text)

Write (copy) to the clipboard asynchronously. Returns a Promise.

text

Type: string

The text to write to the clipboard.

.read()

Read (paste) from the clipboard asynchronously. Returns a Promise.

.writeSync(text)

Write (copy) to the clipboard synchronously.

Doesn't work in browsers.

text

Type: string

The text to write to the clipboard.

.readSync()

Read (paste) from the clipboard synchronously.

Doesn't work in browsers.

FAQ

Where can I find the source of the bundled binaries?

The Linux binary is just a bundled version of xsel. The source for the Windows binary can be found here.

Related

Versions

Version
1.2.2
1.1.0