javascript
javascript copied to clipboard
feat: start support for tanstack in `@clerk/elements`
Description
The following tries to implement support for Tanstack Start/Router because currently error is thrown when @clerk/elements is used there.
Checklist
- [x]
pnpm testruns as expected. - [x]
pnpm buildruns as expected. - [x] (If applicable) JSDoc comments have been added or updated for any package exports
- [ ] (If applicable) Documentation has been updated
Type of change
- [ ] 🐛 Bug fix
- [x] 🌟 New feature
- [ ] 🔨 Breaking change
- [ ] 📖 Refactoring / dependency upgrade / documentation
- [ ] other:
Running tests crashed my machine so.. don't know,. But there's no other changes and there's no tests for that feeture specifically, so current tests should work ok. I'm just quick contributing, someone else could continue.
There's basically just 2 new files alongside the Nextjs ones, so nothign else is changed.
Summary by CodeRabbit
-
New Features
- TanStack Router integration for Clerk Elements enabling SPA navigation.
- Push, replace and shallow navigation methods without full page reloads.
- Automatic base-path detection for consistent URLs.
- Improved handling of optional catch-all routes for accurate path resolution.
- Exposes current pathname and search parameters for UI components.
-
Chore
- Added TanStack Router as a development dependency.