Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

quill-cursors

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

quill-cursors

A multi cursor module for Quill.

  • 0.0.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
5.7K
increased by97.49%
Maintainers
1
Weekly downloads
 
Created
Source

quill-cursors

A multi cursor module for Quill.

Install

Install quill-cursors module through npm:

$ npm install quill-cursors --save

Or you can just take the files from the dist folder. That works too.

Usage

To include quill-cursors in your Quill project, simply add the stylesheet and all the Javascripts to your page. The module already takes care of its registering so you just need to add 'cursors' to your module config when you instantiate your editor(s).

<head>
  ...
  <link rel="stylesheet" href="/path/to/quill-cursors.css">
  ...
</head>
<body>
  ...
  <script src="/path/to/quill.min.js"></script>
  <script src="/path/to/quill-cursors.min.js"></script>
  <script>
    var editor = new Quill('#editor-container', {
      modules: {
        'cursors': true,
      }
    });

    editor.registerTextChangeListener();
  </script>

</body>

To set a multicursor call:

editor.getModule('cursors').set({
  id: '1',
  name: 'User 1',
  color: 'red',
  range: range
});

For more info check out the included example.

Development

Run npm run build to package a build and npm run start to build, start the example webserver and watch for changes.

TODO

A few things that can be improved:

  • Add tests
  • Improve bundling, namely on styles/add minified styles

Keywords

FAQs

Package last updated on 17 Apr 2017

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

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc