react-static: [v6] - Routing - webpack alias doesnt seem to work when building the HTML

building the assets with webpack works fine, but when the build process tries to build the HTML pages i get the following error:

Error: Failed exporting HTML for URL 404 (src/pages/404.jsx): Could not load React-Static routes! Please double check your webpack configuration for consistency and restart/rebuil  d your app. If this error persists, it is likely a webpack resolve.alias problem and you should file an issue at "https://github.com/nozzle/react-static/issues" ASAP.

  - routes.js:2 module.exports
    [app]/[react-static]/routes.js:2:9

  - react-dom-server.node.production.min.js:28 d
    [app]/[react-dom]/cjs/react-dom-server.node.production.min.js:28:492

  - react-dom-server.node.production.min.js:30 ua
    [app]/[react-dom]/cjs/react-dom-server.node.production.min.js:30:494

  - react-dom-server.node.production.min.js:35 a.render
    [app]/[react-dom]/cjs/react-dom-server.node.production.min.js:35:48

  - react-dom-server.node.production.min.js:34 a.read
    [app]/[react-dom]/cjs/react-dom-server.node.production.min.js:34:288

  - react-dom-server.node.production.min.js:45 renderToString
    [app]/[react-dom]/cjs/react-dom-server.node.production.min.js:45:6

  - exportRoute.js:131 renderToStringAndExtract
    [app]/[react-static]/src/static/exportRoute.js:131:21

i was unable to find the correct spot of this bug, the development server works fine…

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Reactions: 3
  • Comments: 19 (14 by maintainers)

Most upvoted comments

Well shoot. I’ll double back and try with a clean install.

On Sat, Oct 6, 2018 at 2:29 AM Bartłomiej Maciejiczek < notifications@github.com> wrote:

Unfortunately, it doesn’t work.

I’ve changed the version to “react-static”: “6.0.0-beta.25”, updated node modules and it wasn’t working. 2.

I upgraded react-static (globally) and created a new project with basic template.

Still the same.

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/nozzle/react-static/issues/793#issuecomment-427556567, or mute the thread https://github.com/notifications/unsubscribe-auth/AFUmCebNPe8u8FXA4aP4di5gIiEQBAIjks5uiGnUgaJpZM4XJpO1 .