@qyloxe No, that’s not the point. I use router hooks and they work fine.
Nevertheless, thanks for the tips.
Latest posts made by mazahaler
-
RE: How to enable data reactivity on the server? (ssr mode)
-
RE: How to enable data reactivity on the server? (ssr mode)
@qyloxe I tried
watch: { $route(to, from) { this.$store.dispatch('app/getById', this.$route.params.id) } }
And that hasn’t changed anything
-
RE: How to enable data reactivity on the server? (ssr mode)
@qyloxe Thanks for the tips. I use beforeCreate and mounted at the same time. beforeCreate is being handled when a user requests a page for the first time and mounted when a user is already on the app and simply goes to different routes.
So far, unfortunately, I have not solved my problem -
How to enable data reactivity on the server? (ssr mode)
Hello. I have the following problem: I am trying to get data from my server in this way:
beforeCreate() { this.$store.dispatch('app/getById', this.$route.params.id) }
(I am also tried to do it with preFetch)
The problem is that the data does not come into the app when I try to get the page for the first time after the app starts. When I get the page a second time, I get the data. But, when I change the id, I do not get new data, instead, I get the data corresponding to the previous id. And I need to reload the page again so that the data is updated.I need to get fresh data when I change the id. How can I do this? Help, please.
-
How to dynamically change html lang attribute on SSR mode?
Hi, I have tried to use Meta plugin, but it’s doesn’t change lang attribute (but can add additional attribute).
meta() { return { htmlAttr: { lang: 'de', why: "I don't know" } ...
Any idea’s how I can change lang dynamically?