fix: TypeScript compat for regex route param
All checks were successful
Build & Deploy to Staging / Build & Deploy to Staging (push) Successful in 10m15s
All checks were successful
Build & Deploy to Staging / Build & Deploy to Staging (push) Successful in 10m15s
This commit is contained in:
parent
56c7a87f3c
commit
01c214e054
1 changed files with 1 additions and 1 deletions
|
|
@ -143,7 +143,7 @@ app.get("/changelog", (_req, res) => res.redirect(301, "/changelog.html"));
|
||||||
|
|
||||||
// Blog routes
|
// Blog routes
|
||||||
app.get("/blog", (_req, res) => res.redirect(301, "/blog.html"));
|
app.get("/blog", (_req, res) => res.redirect(301, "/blog.html"));
|
||||||
app.get("/blog/:slug([^.]+)", (req, res) => res.redirect(301, `/blog/${req.params.slug}.html`));
|
app.get("/blog/:slug([^.]+)", (req, res) => res.redirect(301, `/blog/${(req.params as any).slug}.html`));
|
||||||
|
|
||||||
// Static files (landing page)
|
// Static files (landing page)
|
||||||
app.use(express.static(path.join(__dirname, "../public"), { etag: true }));
|
app.use(express.static(path.join(__dirname, "../public"), { etag: true }));
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue