We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 74b1d7b commit b3d3367Copy full SHA for b3d3367
web/app/config/middleware.ts
@@ -1,4 +1,5 @@
1
import { env } from "app/config/env";
2
+import express from "express";
3
import {
4
defineMiddleware,
5
getDatabase,
@@ -22,13 +23,8 @@ export default defineMiddleware(async ({ app, config }) => {
22
23
redirects: config.http.redirects,
24
}),
25
);
- app.use(
26
- config.http.staticPath,
27
- middleware.staticFiles({
28
- nodeEnv,
29
- dir: config.paths.public,
30
- }),
31
- );
+ // TODO use built-in middleware
+ app.use(config.http.staticPath, express.static(config.paths.public));
32
app.use(middleware.rateLimit({ nodeEnv }));
33
app.use(middleware.json());
34
app.use(middleware.urlencoded());
0 commit comments