content

package
v0.0.0-...-42ca05c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 10, 2019 License: GPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const ArticleTmpl = `` /* 208-byte string literal not displayed */

ArticleTmpl ...

View Source
const ContentArticleTmpl = `<li><a href="%s">%s</a></li>`

ContentArticleTmpl ...

View Source
const ContentPageTmpl = `` /* 191-byte string literal not displayed */

ContentPageTmpl ...

View Source
const ContentSectionTmpl = `<h4>%s</h4><ul>%s</ul>`

ContentSectionTmpl ...

View Source
const ImageTagRegex = `<img\s[^>]*?src\s*=\s*['\"]([^'\"]*?)['\"][^>]*?>`

ImageTagRegex ...

View Source
const ImageTagTmpl = `<p><img src="%s.jpg" middle="true" style="margin-bottom: 20px"></p>`

ImageTagTmpl ...

View Source
const ManifestItemTmpl = `<item href="%s" media-type="%s" id="%s"/>`

ManifestItemTmpl ...

View Source
const NavArticleTmpl = `` /* 216-byte string literal not displayed */

NavArticleTmpl ...

View Source
const NavHeaderTmpl = `` /* 269-byte string literal not displayed */

NavHeaderTmpl ...

View Source
const NavMainTmpl = `` /* 282-byte string literal not displayed */

NavMainTmpl ...

View Source
const NavMapTmpl = `` /* 204-byte string literal not displayed */

NavMapTmpl ...

View Source
const NavSectionTmpl = `` /* 135-byte string literal not displayed */

NavSectionTmpl ...

View Source
const OpfTmpl = `` /* 790-byte string literal not displayed */

OpfTmpl ...

View Source
const SpineTmpl = `<itemref idref="%s"/>`

SpineTmpl ...

Variables

This section is empty.

Functions

func GenerateArticle

func GenerateArticle(article Article) string

GenerateArticle ...

func GenerateContents

func GenerateContents(feed Feed) string

GenerateContents ...

func GenerateManifest

func GenerateManifest(feed Feed) (string, []string)

GenerateManifest ...

func GenerateNavMain

func GenerateNavMain(feed Feed) string

GenerateNavMain ...

func GenerateOpf

func GenerateOpf(feed Feed, manifest string, spine string) string

GenerateOpf ...

func GenerateSpine

func GenerateSpine(feed Feed) string

GenerateSpine ...

func MakeMain

func MakeMain(feed Feed) string

MakeMain ...

Types

type Article

type Article struct {
	ID          int
	Title       string
	Description string
	Content     string
	Author      string
}

Article ...

type Feed

type Feed struct {
	ID          string
	Title       string
	Language    string
	Description string
	BuildDate   time.Time
	Sections    []Section
}

Feed ...

func GetFeed

func GetFeed(path string) Feed

GetFeed ...

type Section

type Section struct {
	Title    string
	Articles []Article
}

Section ...

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL