./localesdirectory. Within this directory there should be a subdirectory for each language supported by the application:
$ go get -u github.com/go-bindata/go-bindata/...
$ go-bindata -o locales.go ./locales/...
LoadAssetsmethod to initialize and load the languages
Assetfunctions are generated by
mapcontaining by its translated text (or template) or/and its pluralized key-values.
"=x"where x is a number
context.GetLocalemethod to determine the current locale or check if the locale is a given value:
context.Trmethod as a shortcut to get a translated text for this request.