标签: express react-router
我有这个:
let dir = __dirname + "/dist" app.use(express.static(dir));
我注销了dir,发现该URL确实与我的webpack(通过bundle.js编译)的位置相同。但是,如果(在Postman中,我为GET运行了localhost:8080/dist/bundle.js,则会收到Cannot GET /dist/bundle.js的响应。
dir
webpack
bundle.js
Postman
GET
localhost:8080/dist/bundle.js
Cannot GET /dist/bundle.js