Quill modules usage
See original GitHub issueHI Do you have an example of how to use quill modules with react-quill.
I could not get quill-markdown-shortcuts to work. Here is the code:
import ReactQuill, { Quill } from 'react-quill';
import { MarkdownShortcuts} from 'quill-markdown-shortcuts';
Quill.register('MarkdownShortcuts', MarkdownShortcuts);
...
render() {
...
<ReactQuill value={'abcd'}
modules={{
MarkdownShortcuts: {}
}}
/>
...
}
...
This is the Error that I get:
quill Cannot import modules/MarkdownShortcuts. Are you sure it was registered?
quill Cannot load MarkdownShortcuts module. Are you sure you registered it?
quill Cannot import modules/MarkdownShortcuts. Are you sure it was registered?
Uncaught TypeError: moduleClass is not a constructor
at SnowTheme.addModule (quill.js:6052)
at SnowTheme.addModule (quill.js:6696)
React-Quill version
1.3.0
Issue Analytics
- State:
- Created 5 years ago
- Reactions:23
- Comments:8
Top Results From Across the Web
Building a Custom Module - Quill Rich Text Editor
Modules are passed an options object that can be used to fine tune the desired behavior. We can use this to accept a...
Read more >Modules | VueQuill - GitHub Pages
Modules allow Quill's behavior and functionality to be customized. To enable a module, simply include it in a modules prop. Example #. In...
Read more >javascript - Quill - how to use modules? - Stack Overflow
I'v got access to the quill instance after initialising it: let quillContainerSelector = '.quill-container'; let quill = new Quill( ...
Read more >Usage of Quill modules in angular universal #1492 - GitHub
I have already read all of the content of the following related Issues: #91 and #57. Error: When running dev:ssr i get the...
Read more >Build a WYSIWYG text editor using Quill - LogRocket Blog
Quill allows users to control which toolbar features to use. The supported options can be divided by the way they are being displayed...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’ve encountered similar issue while using original quilljs (not react-quill) and managed to solve it. In my case, it is due to invalid modules added to quill config.
After removing
variablefrom modules, it worked for me.For anyone encountering this issue, you may want to check if you’ve added unregistered modules to your config.
I had a similar issue when importing and registering a module, my solution was to:
import BlotFormatter from 'quill-blot-formatter/dist/BlotFormatter'Quill.register('modules/blotFormatter', BlotFormatter.default);Hope this helps.