fix: express 5 routing wildcard error for SPA fallback
This commit is contained in:
parent
f71151d19c
commit
9e24cba3b9
|
|
@ -47,7 +47,7 @@ app.use(express.static(BUILD_DIR, {
|
|||
|
||||
// Handle Flutter routes (SPA - Single Page Application)
|
||||
// Any route not found as a static file should serve index.html
|
||||
app.get('*', (req, res) => {
|
||||
app.get('/*', (req, res) => {
|
||||
res.sendFile(path.join(BUILD_DIR, 'index.html'));
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue