-
-
Notifications
You must be signed in to change notification settings - Fork 349
Closed
Description
Templ version
v0.3.960
Describe the bug
I'm trying encore.dev stack with templ, it feels like a hack but it working great expect browser reload when go code changes.
cmd
templ generate -proxy="http://127.0.0.1:4000" -watch -cmd="encore run --browser=never --watch=false" -ignore-pattern="encore.gen.go"
Details
- currently templ waits for proxy to be ready only when it is first initialized. I think it should be whenever we recompile go code.
- the main problem with encore is it's start some kind of an internal reverse proxy (not really sure) even when my app endpoints not picked up by encore just yet. and when templ reloads and hit those endpoints it receives a
502 Bad Gatewaythen I will have to manually reload the browser.
Expected behavior
- wait for proxy restarts for every recompile
- treat 502 bad gateway status code as not ready
If this makes sense I can submit a PR
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels