Skip to content

fix(clerk-react): Improve error message and checks for routing strategies - #2543

Merged
dimkl merged 1 commit into
mainfrom
sdk-1185-routing-stategy-priority
Jan 11, 2024
Merged

fix(clerk-react): Improve error message and checks for routing strategies#2543
dimkl merged 1 commit into
mainfrom
sdk-1185-routing-stategy-priority

Conversation

@dimkl

Copy link
Copy Markdown
Contributor

Description

Apply the following changes to components with routing props:
- default is routing="path" and path prop is required to be set via env or context
- when routing="hash" or routing="virtual" is set the implicit (via env or context) path option is ignored
- when routing="hash" or routing="virtual" then path prop is not allowed to be set

Examples of components with routing props:

  • <CreateOrganization />
  • <OrganizationProfile />
  • <SignIn />
  • <SignUp />
  • <UserProfile />

Checklist

  • npm test runs as expected.
  • npm run 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:

Packages affected

  • @clerk/backend
  • @clerk/chrome-extension
  • @clerk/clerk-js
  • @clerk/clerk-expo
  • @clerk/fastify
  • gatsby-plugin-clerk
  • @clerk/localizations
  • @clerk/nextjs
  • @clerk/clerk-react
  • @clerk/remix
  • @clerk/clerk-sdk-node
  • @clerk/shared
  • @clerk/themes
  • @clerk/types
  • build/tooling/chore

@dimkldimkl self-assigned this Jan 10, 2024
@changeset-bot

changeset-botBot commented Jan 10, 2024

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 19d3f29

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

This PR includes changesets to release 7 packages
NameType
@clerk/clerk-reactMinor
@clerk/chrome-extensionPatch
@clerk/elementsPatch
@clerk/clerk-expoPatch
gatsby-plugin-clerkPatch
@clerk/nextjsPatch
@clerk/remixPatch

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

@dimkl
dimklforce-pushed the sdk-1185-routing-stategy-priority branch from a6f68f5 to 5caad02CompareJanuary 10, 2024 19:17
@dimkl
dimklforce-pushed the sdk-1185-routing-stategy-priority branch 3 times, most recently from af310ca to 79712e9CompareJanuary 10, 2024 19:23
@dimkl
dimklforce-pushed the sdk-1185-routing-stategy-priority branch from 79712e9 to a82be4aCompareJanuary 11, 2024 09:35
Comment threadpackages/react/src/errors/messages.ts Outdated
Comment threadpackages/react/src/errors/messages.ts Outdated
@dimkl
dimklforce-pushed the sdk-1185-routing-stategy-priority branch from 692df41 to 828dbadCompareJanuary 11, 2024 15:06
@dimkl
dimkl enabled auto-merge January 11, 2024 15:07
@dimkl
dimklforce-pushed the sdk-1185-routing-stategy-priority branch from 828dbad to 4a64003CompareJanuary 11, 2024 15:26
@dimkl
dimklforce-pushed the sdk-1185-routing-stategy-priority branch from 4a64003 to 19d3f29CompareJanuary 11, 2024 15:47
@dimkl
dimkl added this pull request to the merge queue Jan 11, 2024
Merged via the queue into main with commit db2d829Jan 11, 2024
@dimkl
dimkl deleted the sdk-1185-routing-stategy-priority branch January 11, 2024 16:06
Sign up for freeto 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.

4 participants

@dimkl@nikosdouvlis@octoper@clerk-cookie