Skip to main content

All Questions

0 votes
0 answers
35 views

Why won't data persist in a component that is reused?

I have a Vue component that is rendered on a route like this: { path: '/chat/:Username(\\w+)?', name: 'ViewChat', component: Chat } The Chat.vue component should render at the path /chat and ...
volume one's user avatar
  • 7,583
0 votes
0 answers
85 views

How to pass props through router link in VUE.JS?

I hope you are having a great day. Actually, I'm curious whether we can pass props through the router link in vue. js or not? Scenario Suppose i have two components. (a) Shop Now (Parent Component) ...
Muhammad Khan's user avatar
0 votes
2 answers
1k views

How to fire an event in mount in Vuejs

I have a sidebar that you can see below: <template> <section> <div class="sidebar"> <router-link v-for="(element, index) in ...
magic bean's user avatar
0 votes
1 answer
530 views

Vue router changing the url but not the content

In Songs component I have a list of other albums, so whenever I click on one it should redirect me on /songs/:id. Each album has it's own id. This is working from Home or any other component, but ...
Sanja's user avatar
  • 326
6 votes
1 answer
13k views

Vue.js 3 - Trying to build a system with 2 layouts

I am a beginner with vue.js (3) I try to build a system with 2 layouts : 1 for a connected user 1 for a not connected user In my router/index.js, I add a meta for each route : const routes = [ { ...
Dom's user avatar
  • 3,446
2 votes
1 answer
2k views

Components which are not defined in SFC are not shown using Vue3 Router?

Now I am trying to create a front-end of a website using Vue3. But now I am having an issue using the Router. Here's my code. Main.js import { createApp } from 'vue' import App from './App.vue' import ...
ZaO Lover's user avatar
  • 433