w-ckeditor-vue
A wrapper for @ckeditor/ckeditor5-vue.
![jsdelivr download](https://img.shields.io/jsdelivr/npm/hm/w-ckeditor-vue.svg)
Documentation
To view documentation or get support, visit docs.
Example
To view some examples for more understanding, visit examples:
default: ex-default.html [source code]
Installation
Using npm(ES6 module):
Note: w-ckeditor-vue is mainly dependent on @ckeditor/ckeditor5-build-classic
, @ckeditor/ckeditor5-vue
and vue
.
npm i w-ckeditor-vue
By import:
<w-ckeditor-vue
v-model="..."
></w-ckeditor-vue>
import WCkeditorVue from 'w-ckeditor-vue'
Vue.component('w-ckeditor-vue', WCkeditorVue)
In a browser(UMD module):
Note: umd file includes with @ckeditor/ckeditor5-vue
, by using tree-shaking for dead-code elimination
[Necessary] Add script for ckeditor.
<script src="https://cdn.jsdelivr.net/npm/@ckeditor/ckeditor5-build-classic@21.0.0/build/ckeditor.js"></script>
[Necessary] Add script for vue.
<script src="https://cdn.jsdelivr.net/npm/vue@2.x/dist/vue.min.js"></script>
[Necessary] Add script for w-ckeditor-vue.
<script src="https://cdn.jsdelivr.net/npm/w-ckeditor-vue@2.0.6/dist/w-ckeditor-vue.umd.js"></script>
Directly use:
<w-ckeditor-vue
v-model="..."
></w-ckeditor-vue>
Vue.component('w-ckeditor-vue', window['w-ckeditor-vue'])
new Vue({
el: '#app',
data: {
content: 'abc中文123'
}
})