-
Notifications
You must be signed in to change notification settings - Fork 669
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
$listeners is readonly error #532
Comments
@eddyerburgh Same problem here. Happened directly after upgrading from vue-test-utils Beta 12 to Beta 13! However, the problem stayed after upgrading from Beta 13 to Beta 14. |
Might be related to #534 |
This is caused by the changes in beta.12 where we set all watchers to sync. We set all watchers to sync, including the update watcher. This causes a re-render when the comonent updates the attrs. Then before the listeners have been updated, |
Is there a workaround for this/plan to resolve? I've confirmed this with Element-UI as well. I don't think this is Vuetify specific. Maybe title should remove Vuetify specifically. https://codesandbox.io/s/q377x6prx9 |
The plan to resolve is to add an async option to Vue that we will set to false. I have a PR open but it won't be added until Vue 2.6 in a months time. The only solution I can think of for this issue is to set Vue to
You can see more info on the synchrnous issue —#676 |
How can I silence these warnings? |
@ticdenis, I believe @eddyerburgh is recommending you set Vue to
|
Thanks! My mistake in silencing was to try it with the localVue instance. |
I'm getting the following logged when running a test which appears related to this issue.
I set I have also tried using Here is what this particular test looks like.
|
I had the same issue @bigtunacan. Modifying mount to use sync: false with the beta.16 version fixed the issue for me.
My entire file looks like this (stubbing a child component, and we use apollo link state instead of Vuex).
|
I was facing this problem while dealing with a component that was using {
stubs: {
transition: false
}
} I'm not sure if all cases are related to these specific settings but, maybe it can be helpful for people facing similar problems. |
Is there any progress on it? |
I believe the fix here is waiting on 2.5.18 for Vue. We have also refactored the entire bootstrap process but it is a breaking change that won't come until 2.0 |
2.5.18 was released |
The issue is still there |
The fix relies on #1062 |
Version
1.0.0-beta.14
Reproduction link
https://codesandbox.io/s/0y2o4p8zvv
Steps to reproduce
Visit reproduction link.
What is expected?
Should not warn
What is actually happening?
Warn that $listerns and $attrs is readonly
The text was updated successfully, but these errors were encountered: