Problem
Currently, only the /streamFile route is configured to serve index.html in the Fastify server. Other React Router defined routes in the SPA will return 404 errors when accessed directly via URL or when users refresh the page.
Current Implementation
In components/log-viewer-webui/server/src/routes/static.ts, we have:
- Static file serving with
wildcard: false
- Specific route handler for
/streamFile that serves index.html
Expected Behavior
All React Router defined routes should be served with index.html so that the React application can handle client-side routing properly.
Related
Problem
Currently, only the
/streamFileroute is configured to serveindex.htmlin the Fastify server. Other React Router defined routes in the SPA will return 404 errors when accessed directly via URL or when users refresh the page.Current Implementation
In
components/log-viewer-webui/server/src/routes/static.ts, we have:wildcard: false/streamFilethat servesindex.htmlExpected Behavior
All React Router defined routes should be served with
index.htmlso that the React application can handle client-side routing properly.Related