devforth / spa-to-http

Lightweight zero-configuration SPA HTTP server. Serves SPA bundle on HTTP port so it plays well with Traefik out of the box. Compatible with Vue.js, React and Angular
MIT License
110 stars 8 forks source link

Bug: Vue or React routers are broken on direct entry pathing #15

Open cghiurea opened 4 months ago

cghiurea commented 4 months ago

Version: 1.0.7

Create a react or vue spa with a router. If you navigate to the router it will return a 404 with your new change of "prevent path traversal outside content directory"

Context our setup on our dev server is Apache reverse proxy to Spa-to-http to React Spa. The second setup is Traefik to Spa-to-HTTP to Vue Spa.

It returns a 404 .

image

Satont commented 4 months ago

Yep, on 1.0.6 version it is working, just tested.

cghiurea commented 4 months ago

@Satont yes, I forgot to mention version 1.0.6 it works. I had to revert to that version on our production servers.

sunaley commented 2 months ago

@Satont yes, I forgot to mention version 1.0.6 it works. I had to revert to that version on our production servers.

I think this might be due to fixing this issue #14 .

cghiurea commented 2 months ago

It is 100% because it tries to reroute and does not work.