-
Notifications
You must be signed in to change notification settings - Fork 460
feat(nextjs): Various DX improvements #2347
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
615e4e2
7685092
f885d52
d04efe7
84c1a31
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| --- | ||
| '@clerk/nextjs': major | ||
| --- | ||
|
|
||
| Drop support for NextJS v12: v12 was released on 26 Oct 2021. Support for security updates stopped on 21 Nov 2022. | ||
|
|
||
| Drop support for NextJS <13.0.4: Various header-related bugs were introduced with the 12.1.0, 12.2.0, 13.0.1, 13.0.2, 13.0.3 NextJS releases which are now fixed since next@^13.0.4. We will be dropping support for these problematic versions in order to greatly reduce complexity in our codebase. | ||
|
|
||
| Drop support for NextJS < 14.0.3 because of the issues described here: https://github.com/clerk/javascript/issues/1436. | ||
|
|
||
| Deprecate `authMiddleware` in favor of `clerkMiddleware`. For more information, see https://clerk.com/docs/upgrade-guides/v5-introduction | ||
|
|
||
| Move the server-side APIs from `@clerk/nextjs` to the `@clerk/nextjs/server` module: `WebhookEventType`, `WebhookEvent`, `verifyToken`, `redirectToSignIn`, `auth`, `buildClerkProps`, `clerkClient`, `currentUser`, `getAuth`, `redirectToSignUp` and `authMiddleware`. For more information, see https://clerk.com/docs/upgrade-guides/v5-introduction |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| '@clerk/backend': major | ||
| --- | ||
|
|
||
| Drop unused SearchParams.AuthStatus constant |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| { | ||
| "main": "../dist/cjs/errors.js", | ||
| "module": "../dist/esm/errors.js", | ||
| "types": "../dist/types/errors.d.ts" | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| export { isClerkAPIResponseError, isEmailLinkError, isKnownError, isMetamaskError } from './client-boundary/hooks'; |
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -29,4 +29,3 @@ const clerkClient = createClerkClient({ | |
| }); | ||
|
|
||
| export { clerkClient }; | ||
| export * from '@clerk/backend'; | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,15 @@ | ||
| export * from './clerkClient'; | ||
| /** | ||
| * Generic exports | ||
| */ | ||
| export { verifyToken, createClerkClient } from '@clerk/backend'; | ||
|
dimkl marked this conversation as resolved.
|
||
| export type { WebhookEvent, WebhookEventType } from '@clerk/backend'; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. After this PR only the following exported types will be available from the
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What about the API types?
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Adding a TODO, I will update the types in a 2nd PR right after |
||
| export { clerkClient } from './clerkClient'; | ||
|
|
||
| /** | ||
| * NextJS-specific exports | ||
| */ | ||
| export { buildClerkProps, getAuth } from './getAuth'; | ||
| export { redirectToSignIn, redirectToSignUp } from './redirect'; | ||
|
|
||
| export { auth } from '../app-router/server/auth'; | ||
| export { currentUser } from '../app-router/server/currentUser'; | ||
| export { authMiddleware } from './authMiddleware'; | ||
Uh oh!
There was an error while loading. Please reload this page.