Skip to content
Advertisement

Tag: vuejs2

vuejs 2 component base64 image not updating

what i want to achieve: load an image from jwt token protected source the server return the image as base64 string and i’ll load this string as background url on the image parent component: myImage component now if i delete a photo (splice) from the form.photos array always the last image get removed. when i remove the green image the

Vue js load modal content with ajax

I’m using vue js with laravel, In my page i have 13 modals, I thing it’s not a good idea to insert 13 modals in the same page so i put this in my blade : And in my file.js i have this : Just for example here i have two modals ‘StatusModal’ and ‘UserModal’ and i load them in

VueJS – How to detect Ctrl+V?

I’ve already seen the answers to this question, but it’s not the solution I need, since it’s for jQuery, and I need something for vue.js. So far, I was able to detect single character presses using the ff. code: The code above successfully prevents the textbox from accepting ArrowLeft, Home, and Control key presses. The problem: I’m trying to figure

VueJs 2.0 emit event from grand child to his grand parent component

It seems that Vue.js 2.0 doesn’t emit events from a grand child to his grand parent component. This JsFiddle solves the issue https://jsfiddle.net/y5dvkqbd/4/ , but by emtting two events: One from grand child to middle component Then emitting again from middle component to grand parent Adding this middle event seems repetitive and unneccessary. Is there a way to emit directly

Vue.js devtool change not showing up

I am currently working with moment.js inside a Vue component but I am not seeing certain changes show up in vue devtools. My example: I am guessing this has something to do with the fact that I am calling a method on my moment data property instead of manipulating it directly like a number. An example like this works perfectly

Async components Vue 2

I’m trying to use async components. Here is my configuration: Vue 2 using Single File Component approach Webpack 2 Vue Router The app is pretty basic, I have an “everyone” section contained in App and an “admin” section contained in Admin. I would like to load the component and all the .js related to the Admin if and only if

Vue props that aren’t explicitly declared

I am making an attempt at something similar to redux-form but in Vue & with Vuex. Basically it should make the handling of forms more streamlined and make you write less boilerplate. The problem i’m having is when i’m trying to pass props dynamically to a component from a HOC. I’m not quite sure how to do it. In React

Vue & conditional rendering with template tag

I am trying to follow documentation: https://v2.vuejs.org/v2/guide/conditional.html But for some reason my template is not working as expected, as soon as I put <template v-if=”variable”> vue fails to render anything. Any advice? Snippets that demonstrate problem: https://jsfiddle.net/o2tL2ems/1/ Answer There is a thing to know about vue.js, Peter pointed it out in a comment. Template cannot be a root element and

Advertisement