前端无法接受后端路由返回的页面

The front-end cannot accept the page returned by the back-end route

后台路由跳转到前端return到页面时,遇到下载页面文件的情况。

enter image description here

enter image description here 点击 时,浏览器会自动下载post.html

尝试使用 res.send 或直接使用 res.sendFile

https://expressjs.com/en/api.html#res.send