tiptap-vuetify
WYSIWYG editor for Vuetify. Component simplifies integration tiptap with vuetify.
Features
- used vuetify components
- support for different types of icons (fa, md, mdi)
- internationalization (en, fr, pl, es, ru, uk, ptbr), with automatic detection of the current language through the Vuetify
- easy to start using
- props and events are available
- TypeScript support
- the project is ready to actively develop if there is support (stars)!
- the ability to create and use your own extensions
- choose where the extension buttons should be displayed: in the toolbar or in the bubble menu
- Vuetify
2.x
and1.x
support
Installation
yarn add tiptap-vuetify
# Or
npm install --save tiptap-vuetify
Get started
NPM (ES modules)
- Installing the package and Vuetify 2 from scratch:
More about vuetify icons you can read here.
- Use in your component. Here is a complete example:
Nuxt
If you have Nuxt.js, here is a description of how to integrate with it.
CDN
There is another use case with the script tag (CDN version of package):
Or
The plugin should be installed automatically after connecting the script.
The only thing is that the Vuetify object must be set in window.vuetify
so that the plugin gets access to it.
Write if you have questions.
Props
placeholder
Placeholder is displayed when there is no content in the editor.
How to use:
extensions
You can use the necessary extensions. The corresponding buttons are added automatically
(in the order in which you specify the extension).
How to import and use them can be seen in the example above.
Available extensions:
Bold
Italic
Strike
Underline
Code
CodeBlock
Paragraph
BulletList
OrderedList
ListItem
Link
Blockquote
HardBreak
HorizontalRule
History
I can easily add more.
toolbar-attributes
You can specify your attributes for the toolbar (<v-toolbar>
vuetify component).
For example, change the color:
editor-properties
Tiptap Editor
properties (passed to the constructor).
You can see the full list of properties here.
Only these properties are not available: content
, onUpdate
, they are used in this package.
If you want to add extensions to the extensions
property, then use the native-extensions
prop of this package.
native-extensions
How to use:
output-format
The format to output from the v-model. This defaults to html
For example, to get json instead:
Events
@init
first argument (object):
How to use:
Slots
toolbar
How to use:
- Since Vue
2.6.0
(new syntax):
- Before
2.6.0
:
footer
Footer of the Editor.
toolbar-before
You can add content before the toolbar.
toolbar-after
You can add content after the toolbar.
TODO
- images uploading (free hosting by default) Relevant issue.
- site with full-docs and examples
- emoticons
- tests
- support for more extensions