Skip to content

Instantly share code, notes, and snippets.

@nicodevs
Created September 16, 2021 22:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nicodevs/b49c094f3e86d472834752fa5d963d6a to your computer and use it in GitHub Desktop.
Save nicodevs/b49c094f3e86d472834752fa5d963d6a to your computer and use it in GitHub Desktop.
CKEditor Vue 2 from CDN
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Demo</title>
</head>
<body>
<div id="app">
<ckeditor v-model="editorData" :config="editorConfig"></ckeditor>
</div>
<script src="https://cdn.jsdelivr.net/npm/vue@2.6.14/dist/vue.js"></script>
<script src="https://cdn.jsdelivr.net/npm/ckeditor4-vue@1.3.2/dist/ckeditor.min.js"></script>
<script>
var app = new Vue({
el: '#app',
components: {
ckeditor: CKEditor.component
},
data: {
editorData: '<p>Content of the editor.</p>',
editorConfig: {
removeButtons: 'Underline,Strike,Subscript,Superscript,Anchor,Styles,SpecialChar,PasteFromWord,HorizontalRule,Source'
}
}
})
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment