You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 7-8.RSVP
Socket
Socket
Sign inDemoInstall

@ckeditor/ckeditor5-clipboard

Package Overview
Dependencies
6
Maintainers
0
Versions
534
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ckeditor/ckeditor5-clipboard

Clipboard integration feature for CKEditor 5.


Version published
Maintainers
0
Created

Package description

What is @ckeditor/ckeditor5-clipboard?

@ckeditor/ckeditor5-clipboard is a plugin for CKEditor 5 that provides clipboard support, enabling users to cut, copy, and paste content within the editor. It handles various clipboard operations, including pasting plain text, HTML, and rich text content, and integrates seamlessly with other CKEditor 5 plugins.

What are @ckeditor/ckeditor5-clipboard's main functionalities?

Basic Clipboard Operations

This code initializes a CKEditor 5 instance with the clipboard plugin enabled, allowing basic cut, copy, and paste operations.

ClassicEditor.create(document.querySelector('#editor'), { plugins: [ Clipboard ] })

Pasting Plain Text

This configuration ensures that only plain text is pasted into the editor, stripping out any HTML or rich text formatting.

ClassicEditor.create(document.querySelector('#editor'), { plugins: [ Clipboard ], clipboard: { plainText: true } })

Handling Custom Paste Events

This example demonstrates how to handle custom paste events by listening to the 'inputTransformation' event, allowing developers to manipulate the pasted content before it is inserted into the editor.

ClassicEditor.create(document.querySelector('#editor'), { plugins: [ Clipboard ] }).then(editor => { editor.plugins.get('Clipboard').on('inputTransformation', (evt, data) => { console.log('Custom paste event:', data); }); });

Other packages similar to @ckeditor/ckeditor5-clipboard

Readme

Source

CKEditor 5 clipboard feature

npm version Coverage Status Build Status

This package implements the clipboard (copy, cut, paste) support for CKEditor 5.

Documentation

See the @ckeditor/ckeditor5-clipboard package page in CKEditor 5 documentation.

Installation

npm install ckeditor5

License

Licensed under the terms of GNU General Public License Version 2 or later. For full details about the license, please check the LICENSE.md file or https://ckeditor.com/legal/ckeditor-oss-license.

Keywords

FAQs

Package last updated on 25 Jun 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc