Skip to content

Commit 3dfe11e

Browse files
author
zhangc
committed
feat:auto commit
1 parent a2ff9d3 commit 3dfe11e

File tree

1 file changed

+36
-29
lines changed

1 file changed

+36
-29
lines changed

examples/vite-example/src/App.vue

Lines changed: 36 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -5,43 +5,50 @@ import "quill/dist/quill.bubble.css";
55
66
import { quillEditor } from "quill-vuejs";
77
export default {
8-
data() {
8+
// data() {
9+
10+
// },
11+
setup() {
912
return {
10-
content: "<h2>I am Example</h2>",
11-
editorOption: {
12-
// Some Quill options...
13+
data: {
14+
content: "", //<h2>I am Example</h2>
15+
editorOption: {
16+
// Some Quill options...
17+
},
1318
},
1419
};
1520
},
16-
components: {
17-
quillEditor,
18-
},
19-
methods: {
20-
onEditorBlur(quill) {
21-
console.log("editor blur!", quill);
22-
},
23-
onEditorFocus(quill) {
24-
console.log("editor focus!", quill);
25-
},
26-
onEditorReady(quill) {
27-
console.log("editor ready!", quill);
28-
},
29-
onEditorChange({ quill, html, text }) {
30-
console.log("editor change!", quill, html, text);
31-
this.content = html;
32-
},
33-
},
21+
// components: {
22+
// quillEditor,
23+
// },
24+
// methods: {
25+
// onEditorBlur(quill) {
26+
// console.log("editor blur!", quill);
27+
// },
28+
// onEditorFocus(quill) {
29+
// console.log("editor focus!", quill);
30+
// },
31+
// onEditorReady(quill) {
32+
// console.log("editor ready!", quill);
33+
// },
34+
// onEditorChange({ quill, html, text }) {
35+
// console.log("editor change!", quill, html, text);
36+
// this.content = html;
37+
// },
38+
// },
3439
};
3540
</script>
3641

3742
<template>
38-
<quill-editor
39-
:content="content"
40-
:options="editorOption"
41-
@blur="onEditorBlur($event)"
42-
@focus="onEditorFocus($event)"
43-
@ready="onEditorReady($event)"
44-
/>
43+
<div>
44+
<quill-editor
45+
:content="content"
46+
:options="editorOption"
47+
@blur="onEditorBlur($event)"
48+
@focus="onEditorFocus($event)"
49+
@ready="onEditorReady($event)"
50+
></quill-editor>
51+
</div>
4552
</template>
4653

4754
<style>

0 commit comments

Comments
 (0)