0👍
Use Gridsome’s <g-link to="/"></g-link>
for the menu items, it will automatically add active
class on the item if it matches current path. You can read more here https://gridsome.org/docs/linking/
- [Vuejs]-Vue.js relative path in data
- [Vuejs]-Vuejs | Create intermediate component that uses one of the props and propagate all remaining stuff to <button> element
Source:stackexchange.com