admin管理员组文章数量:1192940
I'm having an issue serving a next js react app using springboot as a backend.
I have configured my nextjs app (app router) to build it in "export" output. (see screenshoot)
When I serve it statically in my springboot (/resources/static) it is served as a welcoming page by Spring: o.s.b.a.w.s.WelcomePageHandlerMapping : Adding welcome page: class path resource [static/index.html]
When browsing to / my front end is served correctly, when I browse into my website using the buttons and Links from nextjs I don't have any issues.
My problem arise when trying to put urls directly into the browser such as /account/login, im just getting 404s, if I add some controllers to redirect anything into my forward:/index.html It looks like my nextjs static app is not rooting by itself as its supposed to. non specific configuration
I tried everything I found on internet but nothing worked, any idea's?
本文标签: reactjsmapping issue with spring boot and next js react appStack Overflow
版权声明:本文标题:reactjs - mapping issue with spring boot and next js react app - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1738460108a2087984.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论