Documentation
¶
Index ¶
Constants ¶
View Source
const ( // BlockHeader is the header composition block name. BlockHeader = "header" // BlockMain is the main composition block name. BlockMain = "main" BlockFooter = "footer" )
Variables ¶
This section is empty.
Functions ¶
func IsValidBlock ¶
IsValidBlock reports whether name is a known block.
func OrderedBlocks ¶
func OrderedBlocks() []string
OrderedBlocks returns the canonical block order copy.
func SortByBlockOrder ¶
SortByBlockOrder sorts blocks in canonical block order.
func ValidateBlocks ¶
ValidateBlocks validates that every name is a known block.
Types ¶
type Composer ¶
type Composer struct {
// contains filtered or unexported fields
}
Composer stores HTML fragments grouped by page block.
func NewComposer ¶
func NewComposer() *Composer
NewComposer returns a Composer initialized with known blocks.
Click to show internal directories.
Click to hide internal directories.