Skip to content

Conversation

@IAmJSD
Copy link

@IAmJSD IAmJSD commented Dec 18, 2025

What?

Adds support for turning off preflight HEAD requests.

Note I was struggling to test this locally, everything compiles okay, but I was struggling with getting the next build to be within another project. I tried both the tar and linking methods, but had issues with it saying next was outside the project. I am happy to test locally if someone could lend me pointers here.

Why?

For a lot of sites, this is useful. However, for many sites, this is a unneeded request.

How?

Adds a Next configuration option that turns off preflight HEAD requests for those cases.

Whilst very useful in a lot of workloads, if you know you will never have a redirect, it is a wasted request. This PR was mostly AI generated with Cursor, but I manually tested and added the Rust code.
@nextjs-bot nextjs-bot added Documentation Related to Next.js' official documentation. Turbopack Related to Turbopack with Next.js. type: next labels Dec 18, 2025
@nextjs-bot
Copy link
Collaborator

Allow CI Workflow Run

  • approve CI run for commit: 0b75fa6

Note: this should only be enabled once the PR is ready to go and can only be enabled by a maintainer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Documentation Related to Next.js' official documentation. Turbopack Related to Turbopack with Next.js. type: next

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants