# View Iris supports 6 template engines out-of-the-box, developers can still use any external golang template engine, as `context/context#ResponseWriter()` is an `io.Writer`. All of these six template engines have common features with common API, like Layout, Template Funcs, Party-specific layout, partial rendering and more. - The standard html, its template parser is the [golang.org/pkg/html/template/](https://golang.org/pkg/html/template/) - Django, its template parser is the [github.com/iris-contrib/pongo2](https://github.com/iris-contrib/pongo2) - Pug(Jade), its template parser is the [github.com/Joker/jade](https://github.com/Joker/jade) - Handlebars, its template parser is the [github.com/aymerick/raymond](https://github.com/aymerick/raymond) - Amber, its template parser is the [github.com/eknkc/amber](https://github.com/eknkc/amber) - Jet, its template parser is the [github.com/CloudyKit/jet](https://github.com/CloudyKit/jet) ## Examples - [Overview](https://github.com/kataras/iris/blob/master/_examples/view/overview/main.go) - [Hi](https://github.com/kataras/iris/blob/master/_examples/view/template_html_0/main.go) - [A simple Layout](https://github.com/kataras/iris/blob/master/_examples/view/template_html_1/main.go) - [Layouts: `yield` and `render` tmpl funcs](https://github.com/kataras/iris/blob/master/_examples/view/template_html_2/main.go) - [The `urlpath` tmpl func](https://github.com/kataras/iris/blob/master/_examples/view/template_html_3/main.go) - [The `url` tmpl func](https://github.com/kataras/iris/blob/master/_examples/view/template_html_4/main.go) - [Inject Data Between Handlers](https://github.com/kataras/iris/blob/master/_examples/view/context-view-data/main.go) - [Embedding Templates Into App Executable File](https://github.com/kataras/iris/blob/master/_examples/view/embedding-templates-into-app/main.go) - [Greeting with Pug (Jade)`](view/template_pug_0) - [Pug (Jade) Actions`](https://github.com/kataras/iris/blob/master/_examples/view/template_pug_1) - [Pug (Jade) Includes`](https://github.com/kataras/iris/blob/master/_examples/view/template_pug_2) - [Pug (Jade) Extends`](https://github.com/kataras/iris/blob/master/_examples/view/template_pug_3) - [Jet](https://github.com/kataras/iris/blob/master/_examples/view/template_jet_0) **NEW** - [Jet Embedded](https://github.com/kataras/iris/blob/master/_examples/view/template_jet_1_embedded) **NEW** You can serve [quicktemplate](https://github.com/valyala/quicktemplate) files too, simply by using the `context#ResponseWriter`, take a look at the [iris/_examples/http_responsewriter/quicktemplate](https://github.com/kataras/iris/tree/master/_examples/http_responsewriter/quicktemplate) example. ## Overview ```go // file: main.go package main import "github.com/kataras/iris/v12" func main() { app := iris.New() // Load all templates from the "./views" folder // where extension is ".html" and parse them // using the standard `html/template` package. app.RegisterView(iris.HTML("./views", ".html")) // Method: GET // Resource: http://localhost:8080 app.Get("/", func(ctx iris.Context) { // Bind: {{.message}} with "Hello world!" ctx.ViewData("message", "Hello world!") // Render template file: ./views/hello.html ctx.View("hello.html") }) // Method: GET // Resource: http://localhost:8080/user/42 app.Get("/user/{id:long}", func(ctx iris.Context) { userID, _ := ctx.Params().GetInt64("id") ctx.Writef("User ID: %d", userID) }) // Start the server using a network address. app.Run(iris.Addr(":8080")) } ``` ```html