Vue.js is a library for building interactive web interfaces. It creates data-driven user interfaces with a simple and flexible API.
1
vote
1answer
22 views
How to temporize the analysis of an <input> field?
I would like to analyze the content of an <input> field when there is no user activity.
I will take below a simple example (counting the number of characters) but the actual analysis if very ...
1
vote
2answers
20 views
How to comment code in a vue.js file?
I have the need to insert a comment inside a vue.js file for future references, but I don't find how you do this in the docs.
I have tried //, /**/, {{-- --}}, and {# #}, but none of them seem to ...
1
vote
1answer
46 views
Vue.js: How can I update a single item in a “list” - computed property?
I'm trying to determine the best pattern to solve the following:
I want to show a list of people in a specific department
I made the department index a regular, reactive Vue property
I made the list ...
0
votes
3answers
27 views
event.target.blur() not working
I have a series of Bootstrap buttons like this:
<button :disabled="page === lastPage" type="button" class="btn btn-default" @click="getPage(lastPage)">
<span class="glyphicon glyphicon-...
1
vote
1answer
29 views
vue.js proper way to determine empty object
Classic scenario: I want to display a list, but when it's empty I want to display "No data".
The fact that it is somewhat complicated to do something I would expect to be simple makes me think I'm ...
1
vote
0answers
17 views
Vue $refs and kebab case
In vue 1 it was possible to do this:
<app v-ref:test-app></app>
and then reference it like so:
vm.$refs.testApp;
however in vue 2 the syntax for the ref has changed to:
<app ref="...
0
votes
1answer
17 views
Vue order list view
I've been working with vue js 1.27 on a project and I need to be able to sort a list by numeric values, Alphabetic and reverse order.
I've been trying this all day with not really much progress.
I'...
1
vote
2answers
297 views
Vue.js - two different components on same route
I'm trying to figure out how to have 2 different components on same route with Vue.
Main page or login page, depends if user is authenticated.
Maybe im missing something in documentation, but i cant ...
1
vote
3answers
352 views
Can I use slot in a vuejs loop?
I have a template that loops using v-for. In the template I have a named slot with the name being dynamically assigned in the loop. No content is appearing, what am I doing wrong?
<todo-tabs :list=...
2
votes
1answer
106 views
vuejs templates als asp.net partialviews, good practice?
i'm using Vue.js in a Website and added the templates in the html Code and the js-Code in a single js-file.
So i do not want to use the *.vue <-> Vuefy/Browserfy approach but bundle and minify my ...
1
vote
0answers
25 views
Laravel Echo not listening to Event in Vue component
Working on a chat/ message feature for an app. When a User sends a message, I want a specific Event to be triggered and for Laravel Echo to listen to it via pusher from a Vue component. Currently, I ...
0
votes
1answer
16 views
Vue component testing using Karma: 'undefined is not an object'
I am working on an app which was created with the Vue loader's webpack template.
I included testing with Karma as an option when creating the project, so it was all set up and I haven't changed any ...
1
vote
1answer
49 views
Vue.js not correctly rendering dynamically loaded select tag options
I'm trying to render a select tag with options loaded from a Vue object, but, as you can see by the way this is rendered, it looks like something's wrong:
Now this is the markup for the select tag:
&...
0
votes
0answers
12 views
Foundation Orbit in Vuejs 2 template
I am using a foundation orbit in a vue.js 2 single file component. I got it to show but its only working for two slides yet I have four. When I load the page, it slides to the second slide ...
1
vote
2answers
17 views
Vue.js 'v-bind:class' doesn't update even though model does
I've got a list of items, and i want to apply a style to the currently selected one. I'm also using Vuex to manage the state.
My list component:
const List = Vue.component('list', {
template:
...
-1
votes
1answer
25 views
Issue with foundation used in .vue single file components
I have realised that there is a problem when using Zurb Foundation classes in .vue single file components. At first I could not get a Reveal Modal to work inside the .vue component but it was working ...
0
votes
0answers
16 views
Chart.js not rendering properly until window resize or toggling line in legend
I'm trying to make an app to graph tide data using vue.js and chart.js.
I get my data from the Wunderground API using axios, format it for chart.js, then pass it using props to a component to graph ...
0
votes
1answer
17 views
Why is Vue.js Chrome Devtools not detecting Vue.js?
I have the following code with a simple working Vue.js application. But the vue.js devtools is not responding. It was working well a few days ago, now it's not working anymore what could possibly be ...
1
vote
2answers
26 views
disable checkbox after checking two vuejs
how can I disable an array of checkbox after checking a number of checkboxes from that array ?
Is there a way to do this in vuejs or I will need a watcher for that?
In fact I tried to watch the 'ord....
5
votes
2answers
1k views
How to setup ASP.NET Core + Vue.Js?
I Need to integrate Vue.js to some ASP.NET Core MVC views. I picked Vue.js over other alternatives because it seemed to be simpler: -"just add it via <script> tag" they said. No need to learn ...
0
votes
3answers
1k views
Vue JS v-attr=“expression”
Using VUE JS, I'm trying to disable a button if the qty of the item is less than 1.
<div v-repeat = "item: itemsList">
<button v-attr="disabled: {{item.qty}} < 1"> Click </button>...
1
vote
2answers
21 views
use the same form for create and read operation
I have a master and a child component. The child component persists the data for the create mode as well as the edit mode. The child has a data section as follows which is being used when the ...
1
vote
1answer
21 views
Animate using custom directive not working
created a custom directive to extend v-show , v-showblock is adding on true style: display: block;
The transitions/animations are working with v-show but not with v-showblock, which is working ...
0
votes
0answers
9 views
How can I preload data for vue.js in Laravel Spark?
According to the docs and examples, I have perfectly working code that functions great:
Vue.component('admin-competitions-index', {
data: function() {
return {
competitions: []
}
},
...
2
votes
3answers
461 views
Vuex Action vs Mutations (Edited, Said Vuejs)
In Vuejs, what is the logic of having both "actions" and "mutations?"
I understand the logic of components not being able to modify state (which seems smart), but having both actions and mutations ...
3
votes
2answers
40 views
Vue.js 2.0 router link in a div component
I can link like this in vue.js 2.0:
<router-link to="home">Home</router-link>
This compiles to an a tag. But how do I do this with a div?
With vue.js 1.0 I did it like this:
<div v-...
1
vote
1answer
30 views
Vue.js and jQuery datepicker/timepicker two-way binding
Two-way binding with Vue.js using an <input> element doesn't work when jQuery datepicker and/or timepicker updates the <input> value. The binding only happens when a user types inside the &...
0
votes
0answers
17 views
images overlapping with each other using masonry images
I have a problem with a images loaded in masonry. The images are overlapping with each other but when I resize the browser its normal again.
How to fix it?
var $grid = $('#item-container')....
2
votes
1answer
19 views
How to dynamically change Vue.js transition
I want to dynamically change what kind of animation happens depending on a user's action. So for example, when the first button is clicked and the leave animation is called the "hello" element should ...
2
votes
1answer
32 views
How to make Vuex store changes trigger render refresh?
I'm trying to implement some UI components, and currently working on dropdowns. Since opening a dropdown requires closing all others, I'm trying to use Vuex.Store to keep global state, since I've read ...
3
votes
2answers
44 views
Array watch with Vue.js 2
I'm having a set of selects (item.pricelists that are assigned to an item) rendered in a v-for loop and bound with v-model. Possible select options for that item are rendered with another v-for from ...
0
votes
1answer
22 views
Vue.js BreadCrumbs
Currently my BreadCrumbs in vue.js 2.0 look like this:
<template>
<ol class="Breadcrumb">
<li class="Breadcrumb-item">
<router-link class="...
0
votes
0answers
23 views
Converting XML Blob in Javascript [duplicate]
I'm getting back a Blob of XML using Vue-Resource and would like to convert this into a Javascript Object Array.
var books = []
this.$http.get('http://someurl/books.xml')
.then((response) => {
...
0
votes
1answer
19 views
Error: Uncaught (in promise) TypeError: Cannot create property … on string
I'm trying to retrieve data (an array with objects) from my node js server through an ajax request and populate it into my vue instance.
At the following line I get an error:
this.$set('tables', ...
2
votes
1answer
24 views
Cleaner way to require multiple Vue components?
I've just started working with Vue.JS and there's one small issue that's bugging me. My file structure similar to the following:
+ js
|--+ components
| |-- parent.vue
| |-- child.vue
|-- main.js
...
0
votes
0answers
21 views
In an SPA, how to keep server-side data stored in localStorage or sessionStorage from getting too stale?
It makes a lot of sense to store UI-only data in localStorage (browser/machine) or sessionStorage (browser tab) to reduce the complexity of communication across components. The flux/redux patterns on ...
0
votes
4answers
32 views
How to append vue.js event to existing html element
Is there any way to append vue.js events to existing html elements?
HTML elements:
<div class"borrow-button">Borrow</div>
<div class"borrow-button">Borrow</div>
<div class"...
0
votes
0answers
20 views
Best way to implement history function inside Vue.js modal
What would be the best way to implement a history function inside a modal (Vue.js 2)?
In my case, on a ranking page, someone can click on a user profile and a popup is opened with the user's profile....
1
vote
1answer
34 views
In vue.js is it possible to notify “observers” to refetch the value from the observed data, without changing the value of the observed data
Suppose that I have an input element bound like this:
<input :value="somedata">
The user types something in the input, and since I am not using v-model or altering somedata through a handler, ...
1
vote
0answers
23 views
feathersjs open auth2 cookie lost
I've got a nodejs feathers / vue stack.
My server is port 3030 and my client is 4000. I have set up a proxy as:
localhost:4000/api -> localhost:3030
So that I can access my feathers server on ...
-3
votes
0answers
30 views
Full calendar | VueJS
I get event from a django view in JSON format but my events does not appear on the calendar.
I do not understand where my mistake is.
https://gist.github.com/Echel8n/b7ece1353bea10811d06f7e989719e39....
-1
votes
0answers
18 views
How to integrate vuefire to vue-webpack-boilerplate
What steps should be done to use vuefire in the vue-webpack-boilerplate? Following the projects design practices would be a plus.
1
vote
1answer
27 views
VueJS transition “enter” not working
I'm trying to do a fairly simple collapsable menu transition. My element looks like:
<transition name="settings">
<div v-show="!settingsCollapsed">
</div>
</transition&...
3
votes
1answer
40 views
v-for prop value not getting updated with bootstrap modal
I have the following code snippet
<div class="list-group-item media" v-for="evt in event">
<eventmodal :currentevent = "evt"></eventmodal>
</div>
The problem that I am ...
2
votes
4answers
43 views
Setting anchor link to an address in Laravel, gives error
In my Laravel application, when I am trying to link the username of the person who has posted in the website with his profile page, with the code:
<div class="media-body"><a href="@{{ post....
1
vote
1answer
32 views
Vue.js seems to be reverting my list sort
I am trying to re-order a list in vue.js component. After I complete the dragndrop, the order of the list goes a little wonky and no longer matches the actual order of the data that can be seen when ...
0
votes
0answers
26 views
How can I abstract the following pattern? (using Vue.js)
I am learning Vue.js. I like that it is lightweight. I am creating a user interface where there are "Device" objects. Each Device has inputs and outputs that can be accessed by mDevice.inputs or ...
1
vote
2answers
21 views
How exactly do you use mapState?
I'm trying to use mapState in Vuex as follows:
mapState({
locations: state => state.locations,
types: state => state.models.types,
models: state => state.models....
1
vote
1answer
23 views
Vuejs 2 removing from array (splice) not animating with transition
I have a vue component:
<transition-group name="list">
<task v-for="task in tasks" v-bind:key="task.id" v-bind:task="task" class="list-task"></task>
</transition-group>
...
1
vote
1answer
20 views
Vue.js not loading on IE11 with error 'Symbol' is undefined
Using Vue.js on my webapp work on most browsers, except IE11. I tried the default babel-preset-es2015, also tried the babel-preset-es2015-ie, but no luck: the code still not running on IE11 with '...