rsnext/packages/next/client
JJ Kasper 7b6a61a750
Ensure correct locale is used for non-prefixed path (#18708)
When visiting a non-locale prefixed path (`/hello` instead of `/fr/hello`) we don't trigger locale redirects currently so if another locale is matched we need to ensure this is reset to the `defaultLocale` for rendering to prevent a mis-match on the client and the server.

This also fixes hydration errors from occurring with `asPath` for `getServerSideProps` pages due to `normalizeLocalePath` expecting only a pathname and `asPath` containing `hash` and `query values also. 

Fixes: https://github.com/vercel/next.js/issues/18337
Fixes: https://github.com/vercel/next.js/issues/18510
2020-11-02 23:00:41 +00:00
..
dev Remove the static optimization indicator (#18629) 2020-11-02 09:27:36 +01:00
head-manager.ts Fix empty title in head (#17430) 2020-09-28 23:12:07 +00:00
image.tsx Update 3rd party image loaders to prevent upscaling (#18647) 2020-11-02 00:30:17 +00:00
index.tsx Ensure correct locale is used for non-prefixed path (#18708) 2020-11-02 23:00:41 +00:00
link.tsx Ensure preload works correctly with locale option (#18511) 2020-11-02 11:22:40 -06:00
next-dev.js Remove the static optimization indicator (#18629) 2020-11-02 09:27:36 +01:00
next.js Shave a few bytes off the bootstrap code (#14457) 2020-06-22 17:50:17 +00:00
normalize-trailing-slash.ts fix basepath trailing slash (#15200) 2020-07-15 23:53:31 +00:00
page-loader.ts Ensure preload works correctly with locale option (#18511) 2020-11-02 11:22:40 -06:00
performance-relayer.ts Add perf data experiment (#17956) 2020-10-16 16:31:09 -04:00
polyfills.js polyfills 2020-03-30 16:26:25 -04:00
router.ts Update to have default locale matched on root (#17669) 2020-10-08 11:12:17 +00:00
with-router.tsx Convert wrapper class to function component (#9095) 2019-11-09 14:56:59 -08:00