Skip to content

Commit 2af7214

Browse files
Sheraffautofix-ci[bot]
authored andcommitted
refactor(router-core): split loadMatches into its own file (#4969)
After the "flattening" PR #4961, we now have a very clear *separate responsibility* the `Router` class is handling: loading matches. This PR proposes we split the code that handles "loading matches" into its own `load-matches.ts` file, with the entry points being - `loadMatches` - `loadRouteChunk` In future PRs, we might consider splitting other responsibilities out of the 3k LoC `router.ts` file --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
1 parent 8f4fbe1 commit 2af7214

File tree

3 files changed

+991
-1005
lines changed

3 files changed

+991
-1005
lines changed

packages/router-core/src/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ export type {
3939
RequiredToOptions,
4040
} from './link'
4141

42+
export { componentTypes } from './load-matches'
43+
4244
export type {
4345
RouteToPath,
4446
TrailingSlashOptionByRouter,
@@ -197,7 +199,6 @@ export {
197199
defaultSerializeError,
198200
getLocationChangeInfo,
199201
RouterCore,
200-
componentTypes,
201202
lazyFn,
202203
SearchParamError,
203204
PathParamError,

0 commit comments

Comments
 (0)