Skip to content

Tag: vuejs2

Vue.js event after condition element is rendered

I need event or some workaround how to access currently appended element with v-if in jQuery with $(“.myTarget”) if I use watch on showEl variable it triggers before element renders and I can’t access that element yet. How to achieve to be able to access .myTarget immediately after it render…

Table sorting with index assignment

I have an array of objects: I use it as a model for a buefy table and at the same time, I’m using the extension sortable.js to manually order the table rows: The table is rendered correctly, but I need to update the order parameter on each manually sorting to reflect the real order o the table. For exam…

How to use Vuetify tabs with vue-router

I have the following jsfiddle that has two Vuetify tabs. The documentation doesn’t show examples on using vue-router with them. I found this Medium.com post on how to use Vuetify with vue-router, which has the following code: However, the code is now outdated as the Vuetify 1.0.13 Tabs documentation doe…

How to avoid v-if on an element which uses v-for

I have a literal object like so: I was not aware that it was bad to use v-if inside a v-for loop and my first approach to display the code in the view was this: What I was trying to do is to avoid to display a div block related to the type property of the object MenuVoice. Since I

Vue Prop undefined in child component

I am trying to pass an array that inside an object from a parent component to a child component but answers is coming up undefined. When checking the prop in the parent component the data is there, but when it gets past to the child it is undefined. edit: Here is where the parent is declared Parent data: Quer…