0.11.0
This release have some new features, thanks to @justincy and @BjoernRave for these contributions!
🎉 New API things
Proposed by @justincy in #78 and by @BjoernRave in #43, and implemented by @aralroca .
- Link -> Wrapper of
next/link
to navigate to any page with the current language. Read more about it here. - Router -> Wrapper of
next/router
with two extra methodspushI18n
andreplaceI18n
to navigate to any page with the current language. Read more about it here. - clientSideLang -> Useful in some cases to get the current language outside the components. Caveats: don't use it in server-side. Read more about it here.
Improvement of redirectToDefaultLang config
Before was applied only in the i18nMiddleware, with a custom server, doing a 301 redirect from /some/route
to /en/some/route
(if en
is de default language). However, thanks to @justincy contribution now this config also it applies in static mode, doing a redirect on the browser (Router.replace).