Answer the question
In order to leave comments, you need to log in
How to get current route in nuxt?
There is an h1 tag in which you want to display the current route.
How to get this route?
What I have at the moment:
The component in which I need to display the current route:
I have playlists-playlist displayed. I
need to display Playlist 123123
I get the route like this:
<h2>Плейлист {{playlistName}}</h2>
data: () => ({
playlistName: '',
}),
mounted() {
this.playlistName = $nuxt.$route.name;
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question