Skip to content

Tag: vuejs2

How to create dynamic two relational dropdown in Vuejs

I am new to vue.js. I’m stuck trying to dynamically set the options of one select based on the selected value in another. For example, I have two dropdowns named division and district. If value of A is 1, then the district select should load the related codes. I can do it with jQuery but not with Vue. H…

Get element height with Vuejs

I want to get the height of a div in order to make the height of another div matching it. I used the method clientHeight, but It doesn’t return me the good value (smaller value). Actually, It seems to return a height before all elements are charged. After some research online, I tried to put a window.lo…

VueJs dynamic v-on event possible?

Is it possible to set dynamic on event in VueJS? I try to build a dynamic form as component with inputs that can listen on everything. Here an example: Is it possible to set a dynamic v-on event like v-on=”<variable>:<function>”? Answer From Vue 2.4.0+, v-on accepts an object syntax Re…