Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
@ckeditor/ckeditor5-word-count
Advanced tools
Word and character count feature for CKEditor 5.
@ckeditor/ckeditor5-word-count is a plugin for CKEditor 5 that provides word and character count functionality. It is useful for applications where tracking the length of the text is important, such as content management systems, blogging platforms, and educational tools.
Basic Word Count
This code demonstrates how to integrate the WordCount plugin into a CKEditor 5 instance and access the current word count.
const WordCount = require('@ckeditor/ckeditor5-word-count/src/wordcount');
ClassicEditor
.create(document.querySelector('#editor'), {
plugins: [ WordCount, ... ],
toolbar: [ 'wordCount', ... ]
})
.then(editor => {
const wordCountPlugin = editor.plugins.get('WordCount');
console.log(wordCountPlugin.words); // Outputs the current word count
})
.catch(error => {
console.error(error);
});
Character Count
This code demonstrates how to integrate the WordCount plugin into a CKEditor 5 instance and access the current character count.
const WordCount = require('@ckeditor/ckeditor5-word-count/src/wordcount');
ClassicEditor
.create(document.querySelector('#editor'), {
plugins: [ WordCount, ... ],
toolbar: [ 'wordCount', ... ]
})
.then(editor => {
const wordCountPlugin = editor.plugins.get('WordCount');
console.log(wordCountPlugin.characters); // Outputs the current character count
})
.catch(error => {
console.error(error);
});
Customizing Word Count Display
This code demonstrates how to customize the display of the word count by specifying a container element where the word count will be displayed.
const WordCount = require('@ckeditor/ckeditor5-word-count/src/wordcount');
ClassicEditor
.create(document.querySelector('#editor'), {
plugins: [ WordCount, ... ],
toolbar: [ 'wordCount', ... ],
wordCount: {
container: document.querySelector('#word-count-container')
}
})
.then(editor => {
const wordCountPlugin = editor.plugins.get('WordCount');
console.log(wordCountPlugin.words); // Outputs the current word count
})
.catch(error => {
console.error(error);
});
text-statistics is another package that provides various text statistics including word count, character count, and readability scores. It is more comprehensive in terms of the types of statistics it offers compared to @ckeditor/ckeditor5-word-count, but it does not provide direct integration with CKEditor 5.
wordcount is a simple package that provides word and character count functionality. It is lightweight and easy to use but does not offer the same level of integration with CKEditor 5 as @ckeditor/ckeditor5-word-count.
This package implements word count and character count support for CKEditorΒ 5.
This plugin is part of the ckeditor5
package. Install the whole package to use it.
npm install ckeditor5
If you want to check full CKEditorΒ 5 capabilities, sign up for a free non-commitment 14-day trial.
Check out the demo in the word count and character count feature guide.
See the @ckeditor/ckeditor5-word-count
package page in CKEditorΒ 5 documentation.
Licensed under a dual-license model, this software is available under:
For more information, see: https://ckeditor.com/legal/ckeditor-licensing-options.
44.0.0 (December 2, 2024)
We are excited to introduce CKEditor 5 v44.0.0, a release packed with high impact updates designed to enhance your editing experience and simplify access to our premium offers. Here's whatβs new:
We are introducing flexible self-service plans that put you in control with full transparency. Now, you can:
π‘ Important for current users:
If you are upgrading to v44.0.0+, ensure a smooth transition by updating your license keys in the editor, as we implemented a new format of the key. To get the new key, visit the Customer Portal. You can also refer to our license key and activation guide for help with logging in to the portal.
π£ The open-source licensing remains unchanged. However, config.licenseKey
is now a required property in the editor configuration. Use 'GPL'
for installations under the GPL terms. Read more in the update guide.
Say hello to Bookmarks, a long-awaited feature that simplifies content navigation within the editor. With this release, you can:
π Future updates to Bookmarks and the linking experience are planned for the upcoming releases. Follow progress and share your feedback on GitHub.
The current release includes another stride towards improving the performance aspect of the editor, this time focusing on how tables are handled in the content. Implemented optimizations have made table rendering 3x faster, with the average load time of a document with a very long, complex tables dropping from around 4.5 seconds to just 1.5 seconds.
FAQs
Word and character count feature for CKEditor 5.
The npm package @ckeditor/ckeditor5-word-count receives a total of 226,409 weekly downloads. As such, @ckeditor/ckeditor5-word-count popularity was classified as popular.
We found that @ckeditor/ckeditor5-word-count demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.Β It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.