Documentation ¶
Index ¶
Constants ¶
View Source
const (
PS = string(os.PathSeparator)
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Page ¶
type Page struct { // Page title, guessed from the current document. (Looks for the first H1, H2, ..., H6 tag) Title string // The HTML of the current document. Content template.HTML // The HTML of the _header.md or _header.html file on the current document's directory. ContentHeader template.HTML ContentFooter template.HTML // An array of maps that contains names and links of all the items on the document root. // Names begginning with "." or "_" are ignored in this list. Menu []map[string]interface{} // An array of maps that contains names and links of all the items on the current document's directory. // Names begginning with "." or "_" are ignored in this list. SideMenu []map[string]interface{} // An array of maps that contains names and links of the current document's path. BreadCrumb []map[string]interface{} // A map that contains name and link of the current page. CurrentPage map[string]interface{} // Absolute path of the current document. FilePath string // Absolute parent directory of the current document. FileDir string // Relative path of the current document. BasePath string // Relative parent directory of the current document. BaseDir string // True if the current document is / (home). IsHome bool }
This structure holds information on the current document served by Luminos.
func (*Page) CreateBreadCrumb ¶
func (p *Page) CreateBreadCrumb()
Populates Page.BreadCrumb with links.
func (*Page) CreateLink ¶
Returns a link.
func (*Page) CreateMenu ¶
func (p *Page) CreateMenu()
func (*Page) CreateSideMenu ¶
func (p *Page) CreateSideMenu()
Populates Page.SideMenu with files on the current document's directory.
Click to show internal directories.
Click to hide internal directories.