-
-
Notifications
You must be signed in to change notification settings - Fork 349
Closed
Description
Describe the bug
Inconsistent formatting of go code inside {{ }} in templ block.
To Reproduce
templ Collapse(p *CollapseParams) {
{{
if p == nil { // <--- add or remove tabs to see formatting changing
p = &CollapseParams{}
}
p.merge()
}}
@As(p.As, p.Attrs) {
{ children... }
}
}Expected behavior
Should be formatted same each time.
templ info output
(✓) os [ goos=linux goarch=amd64 ]
(✓) go [ location=/usr/local/go/bin/go version=go version go1.24.1 linux/amd64 ]
(✓) gopls [ location=/home/anurag/go/bin/gopls version=golang.org/x/tools/gopls v0.18.1 ]
(✓) templ [ location=/home/anurag/go/bin/templ version=v0.3.857 ]
Desktop (please complete the following information):
- OS: WSL
- templ CLI version: v0.3.857
- Go version: go version go1.24.1 linux/amd64
goplsversion: golang.org/x/tools/gopls v0.18.1
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
