pkg

package
v0.0.0-...-4af8c31 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2021 License: Apache-2.0 Imports: 28 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildSite

func BuildSite(configPath string) error

BuildSite will parse the supplied config file and use it to generate a site

func Serve

func Serve(configPath string, servePort int) error

Serve serves the files fileServeDir via GET requests and echos any POST / PUT requests

Types

type CodeHighlighterRenderer

type CodeHighlighterRenderer struct {
	Style     *chroma.Style
	Formatter *chroma_html.Formatter
	Errors    error
}

func NewCodeHighlighterRenderer

func NewCodeHighlighterRenderer(tabWidth int, style string) CodeHighlighterRenderer

func (*CodeHighlighterRenderer) RenderNode

func (r *CodeHighlighterRenderer) RenderNode(w io.Writer, node ast.Node, entering bool) (ast.WalkStatus, bool)

type EchoHandler

type EchoHandler struct{}

EchoHandler takes the body and writes it back to the client

func (*EchoHandler) ServeHTTP

func (h *EchoHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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