1👍
I am thinking that you can use a v-if
that loads different components depending on the data passed.
<TitleSceneComponent v-if="booleanValueOrCondition" />
<ChoiceSceneComponent v-if="anotherBooleanValueOrCondition" />
This way components can be loaded depending on your conditions.
👤Teej
0👍
I would use vue router to something like this: https://router.vuejs.org/guide/#html
- [Vuejs]-How can I make dynamic parameter on the url?
- [Vuejs]-Triggering resize of Kendo UI Chart in VueJS?
0👍
You can do this:
<component
:is="sceneComp"
v-bind="options"
>
</component>
=============================
computed: {
sceneComp() {
return () => import(`./scenes/common/${this.scene}Component.vue`);
}
👤Odd
- [Vuejs]-No pics or api while generating Nuxt static page
- [Vuejs]-Duplicate values showing everytime navigating to component
Source:stackexchange.com