Documentation ¶
Index ¶
Constants ¶
View Source
const ( RangeKey = "range" BetweenKey = "between" UntilKey = "until" GroupByKey = "groupBy" )
Keys to be used in templates for the functions in this package.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Iterator ¶
type Iterator interface {
Next() interface{}
}
Iterator type can be implemented and used by the `for` command to build loops in templates
func Between ¶
Between will iterate up to, but not including `b`
Between(0,10) // 0,1,2,3,4,5,6,7,8,9
func GroupBy ¶
GroupBy creates an iterator of groups or sub-slices of the underlying Array or Slice entered where each group is of length Len(underlying) / size. If Len(underlying) == size it will return an iterator with only a single group.
Click to show internal directories.
Click to hide internal directories.