Skip to content

Releases: i18nexus/next-i18n-router

v3.1.1

24 Aug 15:39
Compare
Choose a tag to compare

Clean up examples in README to prevent potential linter issues

v3.1.0

19 Jul 13:26
Compare
Choose a tag to compare
  • Adds basePath config option to support using the Next config basePath
  • Adds the currentLocale helper function for retrieving the current language in Server Components
  • Adds the useCurrentLocale hook for retrieving the current language in Client Components

v3.0.1

19 Jul 13:16
Compare
Choose a tag to compare

Minor README update

v3.0.0

24 Jun 07:22
Compare
Choose a tag to compare
  • Pathname language prefix for the default language no longer required
  • Remove need for [lang] dynamic segment by introducing the i18nRewriter
  • getLocale option replaced with localeDetector
  • Cookie detection now independent of localeDetector detection
  • Add config option for prefixDefault

Breaking changes

  • i18nRouter is no longer a default import
// v2.0.0
import i18nRouter from 'next-i18n-router';

// v3.0.0
import { i18nRouter } from 'next-i18n-router';
  • i18nRewriter must be used to create language paths in next.config.js
  • getLocale has been replaced with localeDetector
  • To continue having the default language's pathname prefixed, the prefixDefault option should be set to true

v2.0.0

20 Jun 23:01
Compare
Choose a tag to compare
  • Adds Typescript support

v1.0.2

25 May 17:49
Compare
Choose a tag to compare
  • Adds a default localeCookie named NEXT_LOCALE
  • Fixes a bug when reading request cookies

v1.0.0

10 May 04:38
Compare
Choose a tag to compare

Initial Release