Skip to content

Conversation

@LauraBeatris
Copy link
Member

Description

Portrait #5147

Context

The ability to set clerkMiddleware options with a request callback was introduced here, to cover the cases of setting a satellite domain based on the incoming host.

However, the logic was only tested as synchronously accessing the request, and we forgot to support the callback to be async to cover the other cases as fetching options from an external data source.

The above is indicated in our docs as "dynamically":

CleanShot 2025-02-13 at 16 46 16

Checklist

  • pnpm test runs as expected.
  • pnpm build runs as expected.
  • (If applicable) JSDoc comments have been added or updated for any package exports
  • (If applicable) Documentation has been updated

Type of change

  • 🐛 Bug fix
  • 🌟 New feature
  • 🔨 Breaking change
  • 📖 Refactoring / dependency upgrade / documentation
  • other:

@LauraBeatris LauraBeatris requested a review from a team February 13, 2025 19:46
@LauraBeatris LauraBeatris self-assigned this Feb 13, 2025
@changeset-bot
Copy link

changeset-bot bot commented Feb 13, 2025

🦋 Changeset detected

Latest commit: c8bf4b8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@clerk/nextjs Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel
Copy link

vercel bot commented Feb 13, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
clerk-js-sandbox ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 13, 2025 7:46pm

@LauraBeatris LauraBeatris merged commit ccf4836 into main Feb 13, 2025
37 of 53 checks passed
@LauraBeatris LauraBeatris deleted the laura/async-clerk-middleware branch February 13, 2025 20:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants