Vue Router

Forum rules
Please note that response time for technical support is within 3-5 business days.
Post Reply
itchtp
Posts: 1
Joined: 19 Nov 2021, 04:00

07 Dec 2021, 03:42

Hi, how can I use Vue route "name" prop instead of "to" prop?

Original App.vue

Code: Select all

export default {
    data() {
        return {
	    menu : [
                {label: 'Dashboard', icon: 'pi pi-fw pi-home', to:'/'},
            ]
	}
    }
}
Intended changes

Code: Select all

export default {
    data() {
        return {
	    menu : [
                {label: 'Dashboard', icon: 'pi pi-fw pi-home', name:'Dashboard'},
            ]
	}
    }
}

tugce.kucukoglu
Posts: 560
Joined: 23 Oct 2020, 09:28

07 Dec 2021, 14:21

I do not clearly understand the question. But Avalon uses PrimeVue MenuModel with Vue-Router. If you remove 'to' prop, it will break the routing. MenuModel does not have 'name' prop. Could you check the documentation https://primefaces.org/primevue/showcase/#/menumodel.

Post Reply

Return to “Avalon - PrimeVue”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 4 guests