VueMediumEditor component for Vue 2
vue-medium-editor
This is a project based on simple inline editor toolbar by yabwe. It allows the user to use this toolbar like the one in Medium, which when highlighting text appears and can modify texts to bold, italic, blockquotes etc.
Small example in HTML
<!-- themes -->
<link rel="stylesheet"
href="https://cdn.jsdelivr.net/medium-editor/5.22.1/css/medium-editor.min.css" type="text/css" media="screen" charset="utf-8">
<link rel="stylesheet"
href="https://cdn.jsdelivr.net/medium-editor/5.22.1/css/themes/flat.min.css" type="text/css" media="screen" charset="utf-8">
<body>
<div class="container">
<h1>Vue Medium Editor</h1>
<medium-editor
:text='myText' custom-tag='h3' v-on:edit='applyTextEdit'>
</medium-editor>
</div>
</body>
<script src="https://cdn.rawgit.com/FranzSkuffka/vue-medium-editor/master/dist/vue-medium-editor.min.js">
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.1.8/vue.js">
</script>
<script type="text/javascript">
new Vue({
el: '.container',
data: {
myText: 'A MediumEditor component for Vue 2 '
},
components: {
'medium-editor': VueMediumEditor
},
methods: {
applyTextEdit: function (text) {
this.text = text
}
}
})
</script>
For alternative uses, visit GitHub.