Registry / utility / flosch-pongo2-v5

flosch-pongo2-v5

JSON →
library5.0.0gogounverified

Package pongo2 is a Django-syntax like template engine for Go.

go get github.com/flosch/pongo2/v5
INSTALL
IMPORT
SIG · FLOSCH-PONGO2-V5
F
flosch-pongo2-v5
utilitygov5.0.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

pongo2
✓ github.com/flosch/pongo2/v5

Render a simple template with pongo2.

package main import ( "fmt" "github.com/flosch/pongo2/v5" ) func main() { tpl, err := pongo2.FromString("Hello {{ name }}!") if err != nil { panic(err) } out, err := tpl.Execute(pongo2.Context{"name": "World"}) if err != nil { panic(err) } fmt.Println(out) }
Debug
Known issues
breakingPongo2 v5 introduced breaking changes from v4, including removal of pongo2.RenderTemplateBytes and changes to the template set API.
fix
Update imports from github.com/flosch/pongo2 to github.com/flosch/pongo2/v5 and adjust template set usage.
affects: >=5.0.0
Upgrade
Version history
5.0.0latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
flosch-pongo2-v5 — go get flosch-pongo2-v5 · libregistry