Closed archerLj closed 6 years ago
I want to write text with markdown format in an textArea, and then render it to another vue-markdown div. But the vue-markdown div just show the markdown format text.
this is my code:
<div class="form-group"> <textarea v-model="qContent" class="form-control" placeholder="从这里开始写正文" id="questionContent" style="height: 300px;"></textarea> </div> <div class="markdownArea"> <vue-markdown id="markdownReview"></vue-markdown> </div>
Vue.use(VueMarkdown); var addQaOrNote = new Vue({ el: '#addQaOrNote', data: { qTitle: '', qContent: '', input: '', tags: '' }, watch: { qContent: function (val, oldVal) { $("#markdownReview").html(val); } } })
does vue-markdown's text can not be reset?
I want to write text with markdown format in an textArea, and then render it to another vue-markdown div. But the vue-markdown div just show the markdown format text.
this is my code:
does vue-markdown's text can not be reset?