2
votes

I'm using Nuxt and Vuetify. If I write <nuxt-link>, Nuxt generates <a> tag and the link text is underlined and blue.

I can remove the underline as follows:

a {
  text-decoration: none;
}

Next, I want to fix the color. However, the color depends on the theme (light mode or dark mode).

How to get current mode text color?

2

2 Answers

1
votes

If I'm not mistaken, it can be accessed with this.$vuetify.theme.

The docs are talking about setters but it can totally be used with getters too: https://vuetifyjs.com/en/features/theme/#light-and-dark

And you could change it with something like

this.$vuetify.theme.themes.light.primary = '#4caf50'
0
votes

Try this:

this.$vuetify.theme.currentTheme.primary