File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
packages/react-router-dev/typescript Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import dedent from "dedent";
55import * as Path from "pathe" ;
66import * as Pathe from "pathe/utils" ;
77
8+ import type { RouteConfig } from "../config/routes" ;
89import {
910 configRoutesToRouteManifest ,
1011 type RouteManifest ,
@@ -56,10 +57,13 @@ export async function watch(rootDirectory: string) {
5657 routesViteNodeContext . devServer . moduleGraph . invalidateAll ( ) ;
5758 routesViteNodeContext . runner . moduleCache . clear ( ) ;
5859
59- const result = await routesViteNodeContext . runner . executeFile ( routesTsPath ) ;
60+ const routeConfig : RouteConfig = (
61+ await routesViteNodeContext . runner . executeFile ( routesTsPath )
62+ ) . routes ;
63+
6064 return {
6165 ...routes ,
62- ...configRoutesToRouteManifest ( result . routes ) ,
66+ ...configRoutesToRouteManifest ( await routeConfig ) ,
6367 } ;
6468 }
6569
You can’t perform that action at this time.
0 commit comments