You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] Vue3 support seems not to behave correctly #17723
@plainheart
Could you point me out to something? I can't seem to find much...
It still seems a bug to me given it's not behaving as expected and there's no explaination on what is going wrong...
I mean, if i see no error I don't understand why I get no label, why it doesn't resize and so on...
@Tails128
The following code should solve your problem. It is not a good practice to use the return value of echarts.init as a reactive value. you have a high probability of being wrong because of that.
We've answered many similar issues brought by vue. I believe you may find useful information from the search result if you'd like. But I think it needs to be reiterated that the instance of echarts shouldn't be made reactive as it may affect the access to the properties of inner models and bring some unexpected issues. It's good and suggested to use a normal variable or any shallow API (like shallowRef, shallowReactive) or use markRaw to prevent the instance object from being converted to a proxy.
I see... do you think it would be possible to include this in the "get started" section or in any documentation?
While it's true there are closed issues already, it's not super simple to find them and a simple warning text could save devs a lot of time and it could also save the project a lot of duplicated bugs
Thanks for your suggestion. Though it's possible to mention this issue in the handbook or the FAQ page, I think it is mainly due to the third-party 'vue' and this is not a bug of ECharts. We need to read the documentation carefully and notice the warnings about the usage when using a third-party library. It's always good to report a bug without any external framework.
Activity
plainheart commentedon Oct 5, 2022
Please search related issues with the keyword “vue” and you might find the answer. :)
Tails128 commentedon Oct 5, 2022
@plainheart
Could you point me out to something? I can't seem to find much...
It still seems a bug to me given it's not behaving as expected and there's no explaination on what is going wrong...
I mean, if i see no error I don't understand why I get no label, why it doesn't resize and so on...
YuShengHou commentedon Oct 5, 2022
@Tails128
The following code should solve your problem. It is not a good practice to use the return value of
echarts.initas a reactive value. you have a high probability of being wrong because of that.plainheart commentedon Oct 5, 2022
We've answered many similar issues brought by vue. I believe you may find useful information from the search result if you'd like. But I think it needs to be reiterated that the instance of echarts shouldn't be made reactive as it may affect the access to the properties of inner models and bring some unexpected issues. It's good and suggested to use a normal variable or any shallow API (like
shallowRef,shallowReactive) or usemarkRawto prevent the instance object from being converted to a proxy.See also the tips from the documentation of Vue.js.
In the end, there is a list of partial related issues.
YuShengHou commentedon Oct 5, 2022
Tails128 commentedon Oct 5, 2022
I see... do you think it would be possible to include this in the "get started" section or in any documentation?
While it's true there are closed issues already, it's not super simple to find them and a simple warning text could save devs a lot of time and it could also save the project a lot of duplicated bugs
plainheart commentedon Oct 5, 2022
Thanks for your suggestion. Though it's possible to mention this issue in the handbook or the FAQ page, I think it is mainly due to the third-party 'vue' and this is not a bug of ECharts. We need to read the documentation carefully and notice the warnings about the usage when using a third-party library. It's always good to report a bug without any external framework.
feat(faq): add a new item for Vue-related FAQ. (apache/echarts#17723)
seriously crashing out