Skip to content

Console spam when i18n is enabled #4763

@Su5eD

Description

@Su5eD

Describe the bug

Enabling i18n in Next.js by specifying the i18n property in next.config.ts leads to console spam at startup from Nextra.

Logs

Click to view logs
/opt/homebrew/bin/pnpm run dev

> [email protected] dev /Users/su5ed/*****
> next dev --turbopack

- info [nextra] You have Next.js i18n enabled, read here https://nextjs.org/docs/app/building-your-application/routing/internationalization for the docs.
- info [nextra] You have Next.js i18n enabled, read here https://nextjs.org/docs/app/building-your-application/routing/internationalization for the docs.
   ▲ Next.js 15.4.3 (Turbopack)
   - Local:        http://localhost:3000
   - Network:      http://192.168.50.190:3000
   - Environments: .env.local
   - Experiments (use with caution):
     · optimizePackageImports

 ✓ Starting...
- info [nextra] You have Next.js i18n enabled, read here https://nextjs.org/docs/app/building-your-application/routing/internationalization for the docs.
- info [nextra] You have Next.js i18n enabled, read here https://nextjs.org/docs/app/building-your-application/routing/internationalization for the docs.
 ✓ Ready in 669ms
- info [nextra] You have Next.js i18n enabled, read here https://nextjs.org/docs/app/building-your-application/routing/internationalization for the docs.
 ○ Compiling /[[...mdxPath]] ...
 ✓ Compiled /[[...mdxPath]] in 6.6s
 GET / 200 in 7242ms

To Reproduce

  1. Specify the i18n property in your next.js config
// next.config.ts
const nextConfig = withNextra({
  i18n: {
    locales: ['en', 'de'],
    defaultLocale: 'en'
  }
});
  1. Run Nextra using next dev

Expected behavior

Log messages can be toggled off or are only enabled in debug logging.

Additional context

Nextra version: 4.3.0

if (locales) {
logger.info(
'You have Next.js i18n enabled, read here https://nextjs.org/docs/app/building-your-application/routing/internationalization for the docs.'
)
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions