Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to include the file? #21

Open
tedchou12 opened this issue Jun 9, 2020 · 2 comments
Open

How to include the file? #21

tedchou12 opened this issue Jun 9, 2020 · 2 comments

Comments

@tedchou12
Copy link

tedchou12 commented Jun 9, 2020

Error:

index.html:36 Uncaught ReferenceError: BlotFormatter is not defined
    at index.html:36
<link href="resources/quill.snow.css" rel="stylesheet">
	<link href="resources/quill-better-table.css" rel="stylesheet">
	<script src="resources/quill_2004.min.js"></script>
	<script src="resources/quill-better-table.min.js"></script>
	<script src="resources/quill-image-drop-and-paste.min.js"></script>
	<script src="resources/quill-blot-formatter.min.js"></script>
	<script src="resources/quill-cursors.min.js"></script>
<script>
Quill.register('modules/blotFormatter', BlotFormatter);
	editor = new Quill('#editor', {
        theme: 'snow',
        modules: {
					cursors: true,
          table: true,
          toolbar: {
						container: '#toolbar-container',
						handlers: {
							image: image_upload
						}
					},
					imageDropAndPaste: {
  					handler: image_upload
  				},
					blotFormatter: {
	          // displayStyles: {
	          //   backgroundColor: 'black',
	          //   border: 'none',
	          //   color: 'white'
	          // },
	          // modules: ['Resize', 'DisplaySize', 'Toolbar']
	        },
}
</script>

Thank you!

@tedchou12 tedchou12 reopened this Jun 10, 2020
@QubeApps-Git
Copy link

QubeApps-Git commented Sep 23, 2020

How to register the modules using only script tag without import like React??

@tedchou12
Copy link
Author

I believe you will have to export the module and compile it as a js first.
Remember to use browserify input.js > output.js.

(I gave up on implementing quill because nobody can solve the table issue).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants