Revert importRoute simplification

This caused tests to be included in the built files
This commit is contained in:
Bill Thornton
2025-01-23 16:51:14 -05:00
parent 80a26d5822
commit 91d8a3fffd

View File

@@ -15,7 +15,14 @@ export interface AsyncRoute {
}
const importRoute = (page: string, type: AppType) => {
return import(/* webpackChunkName: "[request]" */ `../../apps/${type}/routes/${page}`);
switch (type) {
case AppType.Dashboard:
return import(/* webpackChunkName: "[request]" */ `../../apps/dashboard/routes/${page}`);
case AppType.Experimental:
return import(/* webpackChunkName: "[request]" */ `../../apps/experimental/routes/${page}`);
case AppType.Stable:
return import(/* webpackChunkName: "[request]" */ `../../apps/stable/routes/${page}`);
}
};
export const toAsyncPageRoute = ({