a-h / templ

A language for writing HTML user interfaces in Go.
https://templ.guide/
MIT License
7.14k stars 236 forks source link

Explanation #812

Closed vitezprchal closed 1 week ago

vitezprchal commented 1 week ago

Hi,

I've reviewed the documentation, but I'm having difficulty understanding this implementation: main.go in the integration-gin example.

Could someone please provide further clarification on what "HTMLRender" does in this context?

joerdav commented 1 week ago

Hey, it allows you to pass a templ component directly to the gin Render component.

c.Render(http.StatusOK, r)