Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not reactive #15

Open
jartaud opened this issue Jun 11, 2020 · 3 comments
Open

Not reactive #15

jartaud opened this issue Jun 11, 2020 · 3 comments
Assignees
Labels
bug Something isn't working hacktoberfest Hacktoberfest 2020

Comments

@jartaud
Copy link

jartaud commented Jun 11, 2020

Step to reproduce:

  1. Create a select element

  2. Watch the data of the select onchange

  3. Set v-model (nothing happens when I change the selected value)

I think the problem is due to this line:

if (!document.getElementById('editor').innerHTML) {

How i solve it:

onSelectType(item) {
      Setting the data to <mc-wysiwyg />  v-model      
      .....
      // The trick to make it reactive
      this.$nextTick(() => {
           document.getElementById('editor').innerHTML = ''
      });
},

Is there any better way?

@jofftiquez jofftiquez added the bug Something isn't working label Aug 21, 2020
@jofftiquez
Copy link
Member

jofftiquez commented Aug 21, 2020

@MAvalleza @jamorajj @MarJaysonSanAgustin @gerald35canonizado would guys mind looking into this? Thanks.

@jofftiquez jofftiquez added the hacktoberfest Hacktoberfest 2020 label Oct 1, 2020
@carlolol
Copy link
Contributor

This could be considered as a bug, depending on the use-case. It isn't reactive for a purpose. If the highlighted line is removed, it will make typing hard as every time you would type, the cursor will go back to the start. You really might have to apply that work around if you want to it to be reactive.

@jofftiquez
Copy link
Member

This could be considered as a bug, depending on the use-case. It isn't reactive for a purpose. If the highlighted line is removed, it will make typing hard as every time you would type, the cursor will go back to the start. You really might have to apply that work around if you want to it to be reactive.

Thanks @carlolol

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working hacktoberfest Hacktoberfest 2020
Projects
None yet
Development

No branches or pull requests

4 participants