fix(shared, nextjs): Support importing @clerk/shared in @clerk/backend#1769
fix(shared, nextjs): Support importing @clerk/shared in @clerk/backend#1769
Conversation
🦋 Changeset detectedLatest commit: 8f52000 The changes in this PR will be included in the next version bump. This PR includes changesets to release 11 packages
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 |
df920f3 to
b90c204
Compare
b90c204 to
20d7932
Compare
20d7932 to
5d6c90b
Compare
|
|
||
| import { buildErrorThrower } from '@clerk/shared'; | ||
| // TODO: replace packageName with `${PACKAGE_NAME}@${PACKAGE_VERSION}` from tsup.config.ts | ||
| export const errorThrower = buildErrorThrower({ packageName: '@clerk/backend' }); |
There was a problem hiding this comment.
I will fix this in another PR that will update how we build and run tests in backend package (currently tsup is not used in tests)
|
|
||
| export function createDevOrStagingUrlCache() { | ||
| // TODO: Check if we can merge it with `./instance.ts#isStaging()` | ||
| const DEV_OR_STAGING_SUFFIXES = [ |
There was a problem hiding this comment.
I will cater this in another iteration where we will evaluate the exports of the @clerk/shared
8fef32a to
f43b75f
Compare
brkalow
left a comment
There was a problem hiding this comment.
Can we add JSDoc comments to the exported methods moved to @clerk/shared as part of this? It should be quick, and leaves it better for the next person to touch this code 🙏
6e815d1 to
2d79433
Compare
|
@brkalow JSDocs added to the moved helpers. ptal |
2d79433 to
f18819e
Compare
|
Since |
This is a preparation step to remove the share-able dependencies from backend package and import them from shared package
`callWithRetry`, `getClerkJsMajorVersionOrTag`, `getScriptUrl`
f18819e to
8f52000
Compare
|
This PR has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |

Description
Review it per commit
Checklist
npm testruns as expected.npm run buildruns as expected.Type of change
Packages affected
@clerk/clerk-js@clerk/clerk-react@clerk/nextjs@clerk/remix@clerk/types@clerk/themes@clerk/localizations@clerk/clerk-expo@clerk/backend@clerk/clerk-sdk-node@clerk/shared@clerk/fastify@clerk/chrome-extensiongatsby-plugin-clerkbuild/tooling/chore