yaminncco / vue-sidebar-menu

A Vue.js Sidebar Menu Component

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to disable router-link

Rishi-Bidani opened this issue · comments

I'm using the side bar as buttons with my own methods, everything is working fine but I keep getting this warning. I'm not using the href parameter.
image

without vue-router you need to make a custom link, check doc https://github.com/yaminncco/vue-sidebar-menu/tree/next#customize-link

without vue-router you need to make a custom link, check doc https://github.com/yaminncco/vue-sidebar-menu/tree/next#customize-link

I apologize, but what custom link will I have to enter if I'm not using href at all?

you can render an hyperlink

const customLink = {
  name: 'CustomLink',
  props: ['item'],
  render() {
    return h('a', this.$slots.default())
  }
}

@yaminncco Thank you so much for your quick response. This is working well.