Replies: 1 comment
-
Finally upgraded to latest version. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When updating the text content of a component, I know it's preferred to use model.components(). However, I use an older version of grapes and it would cause a lot of work to upgrade to the latest version.
In my version, using model.components() to change the text in a widget appends the new content to the existing content. And using model.set('content', value) to change the content of a widget sets the content to an empty value (especially after executing editor.DomComponents.render()).
Q1) Is there a particular reason why this model.set('content', value) sets the value to an empty string?
Q2) After updating the view by executing editor.DomComponents.render(), what exactly changes in the editor that makes using model.set('content', value) doesn't work.
Q3) Is there an easier way to refresh the editor's content without changing the state of existing components? (Before refreshing the content using editor.DomComponents.render(), model.set('content', value) works. After refreshing, it sets the value to null)
Q4) Is there any other way to change the text in a widget apart from using model.set('content', value) and model.components(value)?
Beta Was this translation helpful? Give feedback.
All reactions