File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ export default {
1212 version: Vue .version ,
1313 data: {
1414 value: {
15- // bigint: 124124124124124124124n,
15+ // bigint: 124124124124124124124n,
1616 boolean: true ,
1717 string: ' Hello World' ,
1818 number: 123.456 ,
@@ -33,6 +33,11 @@ export default {
3333 mounted () {
3434 console .log (' expand: ' , this .$refs .jsonEditorVueRef .jsonEditor .expand )
3535 },
36+ methods: {
37+ onInput (data ) {
38+ console .log (' onInput: ' , data)
39+ }
40+ },
3641}
3742 </script >
3843
@@ -49,7 +54,7 @@ export default {
4954 <button @click =" data.value.number = Math.random()" >
5055 改变属性
5156 </button >
52- <button @click =" value = undefined" >
57+ <button @click =" data. value = undefined" >
5358 清空
5459 </button >
5560 <button @click =" mode = mode === 'text' ? 'tree' : 'text'" >
@@ -63,17 +68,18 @@ export default {
6368 <br >
6469 <JsonEditorVue
6570 ref =" jsonEditorVueRef"
66- v-model =" value"
71+ v-model =" data. value"
6772 :mode.sync =" mode"
6873 :readOnly =" readOnly"
74+ @input =" onInput"
6975 />
7076
7177 <br >
7278 <p >Mode</p >
7379 {{ mode }}
7480 <p >Value</p >
75- {{ value }}
81+ {{ data. value }}
7682 <p >Type</p >
77- {{ typeof value }}
83+ {{ typeof data. value }}
7884 </div >
7985</template >
You can’t perform that action at this time.
0 commit comments