Vue.js is a library for building interactive web interfaces. It creates data-driven user interfaces with a simple and flexible API.

learn more… | top users | synonyms

0
votes
1answer
14 views

hide query params in address bar - VueJS

I'm using Vue.js 2 and I'm trying to create a link that should send me to another page. This is what I have: <div v-for="u in myList"> <router-link :to="'/type/' + u.name"><a>{{u....
1
vote
2answers
20 views

Vue - wrap HTML5 element

I want to create a component that wraps a textarea element. Its function is to add custom functionality and custom styling, but I don't want it to be scoped in its own scope - rather, the parent ...
1
vote
3answers
434 views

bLazy and Vue.js - DOM not ready fast enough

I am working on simple gallery with pictures. I wanted to use bLazy plugin to load images, all works fine except the fact that I wanted to load image list via external JSON file and because of that ...
3
votes
2answers
8k views

Dynamic component and template loading with VueJS

I'm considering using VueJS for a multi page website. In the official example of routing, they show that you can dynamically change the template and component based on the URL, but they still have all ...
0
votes
1answer
39 views

SyntaxError: Unexpected token 'const' (with Vue, Karma, Webpack, PhantomJS)

I have a more-or-less vanilla Laravel + Vue.js app and I am trying to do some JS testing with Karma and Jasmine. If I try to use () => {} style functions or keywords like const in my tests, they ...
1
vote
1answer
14 views

Vue PulseLoader given unexpected token with Laravel

I installed the vue-spinner with npm install vue-spinner --save-dev, and I am trying to use the spinner on my file, but when I use the import import PulseLoader from 'vue-spinner/src/PulseLoader.vue'...
0
votes
2answers
31 views

How to create multiple Vue components inside of Bootstrap tabs?

I am using the togglable tabs component in Bootstrap. I would like a table in each tab. Each one is displaying a table of email logs (Click Event, Open Event, etc). I would also like each table to be ...
1
vote
2answers
44 views

How to navigate using vue router from Vuex actions

I am creating a web app with Vue 2.x and Vuex 2.x. I am fetching some information from a remote location via an http call, I want that if that call fails I should redirect to some other page. ...
0
votes
1answer
24 views

How to use Vue Router from Vuex state?

In my components I've been using: this.$router.push({ name: 'home', params: { id: this.searchText }}); To change route. I've now moved a method into my Vuex actions, and of course this.$router no ...
1
vote
2answers
20 views

Vue.js - update parent data with filter

I'm beginner with Vue.js and I would like to update parent data after ajax in component is finished. Problem is when I use filter moment, without filter is everything fine but I need this filter. ...
0
votes
0answers
21 views

Getting error related to webpack when doing unit test for Vue

I had started a webapp, by modifying vue-hackernews-2.0. I started to write unit test as well for it. I am getting following webpack error while setting up unit test for vue web app: 23 11 2016 17:...
0
votes
1answer
19 views

Vue - how to animate table row change

I have animation working on a table when new rows are added or rows are removed. But I'd like to animate rows that change - they aren't added or deleted, but the data bound to that row changes. Is ...
0
votes
0answers
46 views

Vue js combining the elements from two components

I am trying to build the checkout page of a e-commerce type of app. On the checkout I have a list of OrderItems coming from the database, each with price, quantity. You can pick and combine these. In ...
-1
votes
0answers
29 views

Create a sceduler calendar

I am trying to create a simple schedule calendar with vue.js. Something like in this image. I know there exists many plugins I could use with other frameworks, but because I am still in learning ...
0
votes
2answers
29 views

Two way binding between controller in routerview and parent

I have a single page application which consists of a: A navigation component which contains a title and a menu A router-view I'd like each component being presented in the router view which ...
0
votes
2answers
25 views

Proper approach to showing subviews using Vue

I'm new to Vue and trying to observe the paradigm of it, I checked the page, did the examples and compared to Angular, MVC etc. that I'm substantially convenient with. My scenario is as follows. ...
2
votes
2answers
35 views

A simple datepicker in VueJS

I want to make a datetimepicker in a components input tag. I have implemented bootstrap-datetimpicker but when i choose date i cant get input value in the components methods( here is an example: https:...
8
votes
2answers
7k views

Call a Vue JS component method from outside the component

Let's say I have a main Vue instance that has child components. Is there a way of calling a method belonging to one of these components from outside the Vue instance entirely? Here is an example: ...
0
votes
1answer
24 views

Invalid or unexpected token in my Vuejs javascript file

In my vue component js code, I received this error: Uncaught SyntaxError: Invalid or unexpected token This is my code: Vue.component('pickpoint-info', { template : '<table>\ // in this ...
1
vote
2answers
75 views

Vue 2.0 - Failed to mount component: template or render function not defined despite defined render function

Working on an SPA using Vue 2.0. I'm bundling all my templates with Webpack from .vue files via Laravel Elixir, laravel-elixir-webpack-official and laravel-elixir-vue-2. I've reviewed pretty much ...
5
votes
2answers
2k views

Vuejs - Hide vuejs syntax when page loading

maybe this is a trivial question. so, when I run my vuejs application on browser with enables throttling download speed (sets to low connection). I got unfinished vue syntax output in browser. I ...
0
votes
2answers
21 views

How to call vue instance outside it in Javascript

How can I call the test vue in javascript? Here is my code, I want to call test when I do something in javascript function. function clickit() { this.test.fetchTestData(); } var test = new ...
-1
votes
2answers
45 views

Get name of parent object in array loop

I have the following array of objects: payload: [ {name: one}, {name: two, values: {name: five} }, {name: three}, {name: four} ] I loop through this in a recursive way, ...
0
votes
1answer
7 views

Simulate tab key

anyone know how to simulate tab key to move through the inputs? <input type="text" @keyup.enter="myfunc"> <input type="text" @keyup.enter="myfunc"> <input type="text" @keyup.enter="...
1
vote
1answer
21 views

Vue.js - Component with two rowspan

I'm beginner with Vue.js and I would like to use component. I have a (dynamic) table with machines (SN = serial number) and their money for each source so I want to use rowspan. Each row will be ...
1
vote
1answer
43 views

app.message returns undefined in console using Vue in Laravel

I've just started learning Vue, and have been following there intro guide, but am stuck at the: Just open up your browser’s JavaScript console and set app.message to a different value. I tried ...
1
vote
1answer
29 views

Redirect from method in Vue.js with Vue-router older than version 1.x.x

I'm not much of a frontend developer but I know enough javascript to do the minimum Im trying to plug into a last piece of login however my vue components are "vue-resource": "^0.9.3", "vue-...
0
votes
1answer
27 views

Vue component select some options by default

UPDATE: the issues does not reproduce with "CDN" style. Here's the perfectly working JSBin: https://jsbin.com/ziqasifoli/edit?html,js,output It looks that it is connected to something amongst webpack/...
2
votes
2answers
36 views

Vue.js Cannot read property 'length' of null

If I do this: <div class="panel panel-default" v-if="socialiteLogins !== null"> The panel doesn't hide. If I check socialiteLogins === null alone, or with ==, they both return that the object ...
0
votes
1answer
39 views

VueJS: Why does this.$set() throw error?

I am using the $set method to let Vue know that the object has changed and it keeps throwing the following error. Am I misusing the method? Error TypeError: exp.trim is not a function. (In 'exp.trim(...
2
votes
1answer
52 views

How / why to switch from <script> includes to npm installs?

I have a VueJS project that uses npm to manage all the Vue stuff (vue-resource, router, Vuex etc). But in my index.html file I've also got a bunch of other stuff included via script tags: Bootstrap ...
1
vote
1answer
36 views

incrementing and rendering different views in different elements in a foreach loop

I have been learning "code" just over a year for a project i have and have got stuck on a particular function that i am trying to create for the user. I have lots of divs with different information ...
3
votes
1answer
526 views

Vue: How to use store with component?

//store export default { state: { aboutModels: [] }, actions: { findBy: ({commit}, about)=> { //do getModels var aboutModels = [{name: 'About'}] //Vue.resource('/abouts')....
0
votes
1answer
29 views

Stop multiple field filling with v-model?

I'm pretty new to Vue.js and while I've figured most of the problems I'm hitting out, I can't get my head around this one. I'm displaying a list of posts based on API output, and want to have a ...
0
votes
1answer
23 views

Get options of component by plugin

In my component i have this option (my_plugin) <script> export default { ready () { // ... }, my_plugin: 'test' } </script> In my plugin, i need get 'my_plugin', ...
0
votes
0answers
19 views

Vue.js I18n not setting language

I'm using Vue.js 2 and the I18n plugin to create a multilanguage website. The required language file (in my example nl) is requested from an external url. Unfortunately I can't get it working. ...
0
votes
0answers
12 views

Vuikit modal not showing

I am using the code from the official documentation - https://vuikit.github.io/vuikit/#/modal <vk-button @click.native="show = true"> Open </vk-button> <vk-modal :show="show" @...
0
votes
1answer
41 views

Vue js event not picked up

I have just started experimenting with vue js and I am building a checkout form with it. I am also using Symfony 31 for the project. On the checkout/signup page I have an embedded collection of forms ...
3
votes
2answers
69 views

Vue.js - Emit event from directive

Is it possible to emit a custom event from the directive in the component to which this directive is attached. I was expecting it to work as described in example, but it does not. Example: //Basic ...
1
vote
1answer
23 views

VueJS checkbox update

I'm a little wired with VueJS states. This is my simple app : new Vue({ el: '#media-app', data: { activeTypes: [], activeCategories: [], medias: [] }, ...
0
votes
1answer
48 views

how do i toggle the classes of individual <li> elements?

when I toggle a class from true to false, currently all elements trigger on and off at the same time. How do I target them individually? the Todo-List example has similar functionality (with todo /...
0
votes
2answers
35 views

Scroll to bottom of div with Vue.js

I have a Vue component with several elements in it. I want to automatically scroll to the bottom of that element when a method in the component is called (basically, do the same as in Scroll to bottom ...
0
votes
0answers
9 views

How to pair Html elemens with lines of code in Ace editor

I'm programming interactive html editor using Ace editor and Vue Js. Code from Ace editor is automatically rendered as html preview using Vue. Now i would like to add interactions, such as click on ...
3
votes
1answer
32 views

Vue router inherit parent properties

I'm fairly new to vue.js and I'm currently trying to setup my different routes. I'm using sub routes, since the "logged in" user will have a different UI than a visitor. Currently my setup is like ...
0
votes
0answers
12 views

Having a hard time with async vue router to vue fire

Im using vue fire as a plugin for connecting to firebase easily integrated with VUE JS and VUE router im really having a hard time solving the null thing after manually binding like this line of ...
3
votes
3answers
82 views

Find and update value in array of nested objects

I have an object array as follows: products = [ { id: 1, title: "Product 1", specifications: { price: 1.55, discount: 15, attributes: [ { l1: 100, ...
1
vote
0answers
31 views

Using Flow.js in Vue.js

I'm trying to use flow.js with vue.js but I'm running into issues getting it to work in .vue files. I ran vue init webpack, npm install -g flow-bin, and then npm install and npm run dev. I was able ...
0
votes
2answers
49 views

VueJS - Invalid handler for event “click”: got undefined

I have list of elements which I want to go to edit when clicked. I have similar solution in other component and it is working perfectly fine but in new one it is not and can't find why. When ...
1
vote
1answer
18 views

How to reassess a computed value upon key press?

I would like to display a different random word from a list upon pressing a key. The "displaying a random word" part works fine: var vm = new Vue({ el: "#root", data: { verbs: ['...
1
vote
3answers
37 views

'window' is not defined in Vue.js 2

I'm currently upgrading my application from Vue.js 1 to Vue.js 2. I have a problem with the following function in my main component: <script> export default { ready: function listenKeyUp()...