throw render() with i18n with client routing doesn't work properly #1436
-
Hi, I'm currently learning Vike, congratulations for this amazing project. I want to render a certain page based on a guard. After a little bit of investigation, adding "+onBeforeRender" makes the client fetching data on "xxx/index.pageContext.json" on each route change. But i haven't found a method to get this page translated. I tried this
Is there something I'm not doing right? Here is a minimal reproduction : https://github.com/lebretont/vike-i18n-client. Thanks for the help! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 7 replies
-
Indeed, I could reproduce the issue. I'll have a closer look at it tomorrow. |
Beta Was this translation helpful? Give feedback.
-
I'm still playing with vike so this is not urgent.
Thanks for reviewing it.
|
Beta Was this translation helpful? Give feedback.
Fix pre-released in
0.4.156-commit-d8d55d2
.Also make sure to correctly use
throw render()
and usepageContext.urlPathname
instead ofpageContext.urlOriginal
. (Further improving docs about this is on the radar.)Apologies for the delayed handling of this bug. It wasn't a trivial one and writing docs for
vike-{react,vue,solid}
is getting quite important. Usually such bugs are fixed under 24h.I guess it's too early but would your company, eventually, be up for sponsoring?