Closed elouanmailly closed 2 months ago
Ref: INT-2795
up
I have same question,I can't imagine such a simple problem happening
This is because in vue3 we have model-value. not "value"
up,this question not repair!!!
This is my setup, hope it helps:
const tinyConfig = {
// Your setup here
skin: false,
plugins: "lists link image table code help wordcount",
content_css: false,
branding: false,
promotion: false,
// The important part
setup(editor) {
editor.on("input", () => handleInput(editor.getContent()));
},
};
const handleInput = (editor) => {
// Do whatever you want here
console.log(editor);
};
<Editor :init="tinyConfig" />
This issue is stale because it has been open 30 days with no activity. Please comment if you wish to keep this issue open or it will be closed in 7 days.
This issue was closed because it has been stalled for 7 days with no activity.
What is the current behavior?
After initializing a component with the
<script setup>
syntax, it seems that the value binding does not work.https://codesandbox.io/s/tinymce-editor-script-setup-x4dvkp
What is the expected behavior?
The initial value in the editor should be "initial-content" and when the button is clicked, the value should change to "Change value with button"
Which versions of TinyMCE, and which browser / OS are affected by this issue? Did this work in previous versions of TinyMCE or tinymce-vue?
Vue: 3.2.31 Vite: 2.8.6 @tinymce/tinymce-vue: 4.0.6 tinymce: 6.0.0