0

I have a test repo for this problem (Link)

I think it's a problem with localization file. I use react-intl.

Dev version works good.

The problem is:

  • create production build
  • run production server
  • open app http://localhost:3001/activities
  • refresh page (works normal)
  • click on Link to id 1 (works normal)
  • refresh page (not work, because 1.bundle.js file not sent correctly, css too)

What is 1.bundle.js? I think it is localization file. (some info). How I can fix it?

Max P
  • 1,439
  • 3
  • 15
  • 33

1 Answers1

0

The problem was in production config. I forgot publicPath setting.

...
output: {
  path: path.join(__dirname, 'production/public/'),
  filename: 'bundle.js',
  publicPath: '/' // this will make sure that all statics are hit at '/' route
},
...

Pull request link

Max P
  • 1,439
  • 3
  • 15
  • 33