Skip to content

Commit

Permalink
[docs] Update README.md with features description
Browse files Browse the repository at this point in the history
  • Loading branch information
dinever committed Apr 18, 2016
1 parent 88b10a8 commit b4e6385
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,37 @@ Homepage: [golf.readme.io](https://golf.readme.io/)

go get github.com/dinever/golf

## Features

1. Dead simple template inheritance with `extends` and `include` helper comes out of box.

**layout.html**

```html
<h1>Hello World</h1>
{{ template "body" }}
{{ include "sidebar.html" }}
```

**index.html**

```jinja2
{{ extends "layout.html" }}

{{ define "body"}}
<p>Main content</p>
{{ end }}
```

**sidebar.html**

```jinja2
<p>Sidebar content</p>
```
2. Built-in XSRF and Session support.
3. Powerful middleware chain.
4. Configuration from a JSON file.

## Hello World

```go
Expand Down

0 comments on commit b4e6385

Please sign in to comment.