Add funcmap description in the README

This commit is contained in:
Manfred Touron 2016-12-10 17:23:59 +01:00
parent 19a3db3d08
commit 1146013b1f
No known key found for this signature in database
GPG Key ID: 9CCF47DF1FD978A1

View File

@ -38,6 +38,28 @@ $> protoc --gotemplate_out=debug=true,template_dir=/path/to/template/directory:.
See [examples](./examples). See [examples](./examples).
## Funcmap
This project uses [moul/funcmap](https://github.com/moul/funcmap) library to extend the builtin [text/template](https://golang.org/pkg/text/template) helpers.
Non-exhaustive list of new helpers:
* `json`
* `prettyjson`
* `indent`
* `split`
* `join`
* `title`
* `unexport`
* `add`
* `trimspace`
* `lower`
* `upper`
* `rev`
* `int`
See the project for the complete list.
## Install ## Install
* Install the **Go** compiler and tools from https://golang.org/doc/install * Install the **Go** compiler and tools from https://golang.org/doc/install