heroku router cannot get

Solutions on MaxInterview for heroku router cannot get by the best coders in the world

showing results for - "heroku router cannot get"
Milan
25 Jan 2020
1// use this after route not before route
2if (process.env.NODE_ENV === 'production') {
3  app.use(express.static(resolve(process.cwd(), 'client/build')))
4  app.get('*', (req, res) => {
5    res.sendFile(resolve(process.cwd(), 'client/build/index.html'))
6  })
7}