Skip to content

Turbopack and next-intl/plugin - The config property experimental.turbo is deprecated. #1838

Closed
@theoludwig

Description

@theoludwig

Description

With the release of Next.js v15.3.0, we can try next build --turbopack.

By doing so with the following next.config.js:

import createNextIntlPlugin from "next-intl/plugin"

const withNextIntl = createNextIntlPlugin()
export default withNextIntl()

It yields this warning:

 The config property `experimental.turbo` is deprecated. Move this setting to `config.turbopack` as Turbopack is now stable.

This is because of those lines:

nextIntlConfig.experimental = {

Is there a way to detect the Next.js version used, and if above than v15.3, then we don't use experimental.turbo, but directly in the turbo property, otherwise we keep current behavior for older versions to avoid breaking changes?

Or maybe, we can't do it automatically, but at least we could provide a param to withNextIntl, to tell that we should put turbo config under turbo property, and not with experimental.turbo.

Verifications

Mandatory reproduction URL

https://github.com/amannn/next-intl/tree/main/examples/example-app-router

Reproduction description

Steps to reproduce:

  1. Install next-intl to a project with Next.js v15.3.0
  2. Run next build --turbopack
  3. See the warning

Expected behaviour

No warnings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingupstream-issueThis issue is caused by an upstream dependency (e.g. Next.js)

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions