chore: upgrade from remix to react router v7#20
Open
LIlGG wants to merge 7 commits intohalo-dev:mainfrom
Open
Conversation
Migrated API route files from dynamic Remix v2 file system routing to a flat, explicit structure compatible with React Router v7. Removed all dynamic route handler files and replaced them with direct route modules under organized folders (e.g., api/chat, api/1panel, etc.). Updated route configuration in routes.ts to use the new structure and prefix helpers. Refactored all API handler modules to include authentication checks directly and removed indirection via action/loader wrappers. Updated imports and fixed references throughout the codebase to match the new file locations. Also updated Netlify deploy action endpoint and improved error handling in 1panel store.
Refactored several route handler functions to remove unnecessary exports and align with new conventions. Updated Chat component to receive loaderData via props and adjusted usage in chat route. Removed unused 'data' utility from routes. Minor UI component cleanup and fixed transition utility in uno.config.ts.
Deleted the AuthErrorToast component and its lazy loader from the codebase. Upgraded all @react-router/* and react-router dependencies from version 7.10.1 to 7.11.0 in package.json and pnpm-lock.yaml.
Replaces manual type definitions for route loader data with types from generated Route types, improving type safety and maintainability. Updates useRouteLoaderData calls and adjusts route registration to use explicit route IDs, aligning with new type usage.
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What type of PR is this?
/kind feature
What this PR does / why we need it:
从已归档的 remix v2 升级到 react router v7 版本。
Does this PR introduce a user-facing change?