When users are not logged into my website, the state of user is set to null. However, this throws up a lot of issues on some pages where i look to see if this.$store.user For example, if I were to have a simple check such as and the user is not logged in (thus, setting the state of user to
Tag: vue.js
uploading and downloading storage images in firebase with VueJs
im building this simple application using Vue/vuex and firebase where i want to facilitate users upload images and once the app gets updated those images get reached from firebase storage , modifying the current database with the new uploaded image Here is my code: the images get push to the firebase storaged but once i try to modify the database
Change buttons color in a vuetify list
After having tried to figure this out for two days I thought I will ask you. I think I do have a simple problem, however because of limited knowledge I’m not able to find a solution. Basically, I do have a list with OK/NOK buttons and I want to change the background color of the (clicked) button (either green or
Vue drag & drop in Recursive component & recursive nesting
Im working with Vue to create recursive Tree component, currently I have added support for checkboxes and expanding nodes, but Im having a bit of trouble with building drag & drop in recursive component Is there any way to implement drag & drop with this sample: Codesandbox Link I can get node that is dragged but on drop I do
vuetify v-data-table not showing nested object data
I have v-datatable using vuetify I want to get nested data to be displayed unfortunately I can’t get the nested object value this is my code and this is the header and my data i got the values but not the nested one it displays [object Object] Answer replace to
Vue.js – Unit testing component with complex children
Let’s assume a basic Bootstrap driven HTML form as part of a custom Vue component MyForm.vue A unit test for testing if the template is rendered successfully is pretty simple This line works field.element.value works because field.element is of native type HtmlInputElement with value attribute. What if I want access an attribute of a complex component let’s say of b-form-input,
Vue split components from a single .js file in multiple files
I have created a component inside my index.js (where my main Vue code is). Now I would like to modularize the project and put the component into a separate file. I don’t know how to do that because if I create e.g. optionalapm.js the main index.js returns an error that it can’t locate the vue component optionalapm which I included.
Race condition with multiple responses from asynchronous axios calls in a vuejs app
I am running multiple axios.get() calls in my Vue.js app. I would like to call another function after all of the fetches have received responses. How can I do this? I have read about Promise.all(). If this would help me, please advise on how to incorporate Promise.all into my code. If I add async and await to my code like
Problems with my API in Vue.js with axios
I’m creating a bookstore app with Vue.js. The books are in this API https://api.myjson.com/bins/1h3vb3, but I can’t show them in my HTML with the following function and I don’t understand why: Answer axios.get resolves to a Response, which stores the received data in the data property. In your code, you’ve incorrectly set this.books to response, which is the entire Response
HTML in Vue.js not updating after axios get request updates object’s property
HTML in Vue.js not updating after axios get request. HTML is: data: method: This is all happening in a file called App.vue (if that is important). If I look in chrome dev tools Vue, I can see the data object does update and populate with the correct information. But it doesn’t update in the html on the page. Edit: Everything