Skip to content

Commit 4929ae1

Browse files
authored
Fix middleware ordering so static assets load (#128)
literally can't believe how dumb this fix was Issue was that https://euno.reactiflux.com/ looked like this <img width="499" alt="Screenshot 2025-04-18 at 4 59 55 PM" src="https://github.com/user-attachments/assets/83f549cb-ebd1-4884-afeb-c9ce820a0506" /> instead of like this <img width="565" alt="Screenshot 2025-04-18 at 5 00 12 PM" src="https://github.com/user-attachments/assets/38b34bc6-63c4-4508-b297-dd4d475305f8" /> Should be fixed now
1 parent ddae9ed commit 4929ae1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index.prod.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ import { app as rrApp } from "./build/server/index.js";
1010
const app = express();
1111

1212
console.log("Starting production webserver");
13-
app.use(rrApp);
1413

1514
app.use(
1615
"/assets",
1716
express.static("build/client/assets", { immutable: true, maxAge: "1y" }),
1817
);
1918
app.use(express.static("build/client", { maxAge: "1h" }));
19+
app.use(rrApp);
2020

2121
/** ERROR TRACKING
2222
Must go after route handlers

0 commit comments

Comments
 (0)