DEV Community

Discussion on: [VUE] How to access a variable from another instance

Collapse
georgehanson profile image
George Hanson

Is there a reason you are using three different instances? Ideally, you should only be using one instance of Vue and then everything else is components.

Collapse
imrc21 profile image
IMRC21 Author

Thank you for your answer.
I am using more instances because Onsen UI (CSS framework) doesn't let me use one single vue instance.
Don't know why but if I use only one instance it does not show me anything.

Collapse
eladc profile image
Elad Cohen

Very strange.. can you show that in jsFiddle?
You should also check this repo (bit old): github.com/frandiox/onsenui-vue-ro...

Thread Thread
imrc21 profile image
IMRC21 Author

jsfiddle.net/ejm59tpo/1/

This is my code, on JsFiddle works the framework but not vue but I guess that's normal.
Also, my project is based on Cordova, I don't know if this could be related.

Thanks for that repo, however I'd like to keep the project simple.