site

package
v0.0.0-...-394db76 Latest Latest
Warning

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

Go to latest
Published: May 3, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config interface {
	URLConfig
	Languages() []LanguageConfig
}

type ContentSpec

type ContentSpec interface {
	PreparePages() error
	RenderPages(func(kind string, sec []string, dir, name string, buf *bytes.Buffer) error) error
}

type Descriptor

type Descriptor struct {
	// The content to publish.
	Src io.Reader

	// The OutputFormat of this content.
	OutputFormat valueobject.Format

	// Where to publish this content. This is a filesystem-relative path.
	TargetPath string

	// If set, will replace all relative URLs with this one.
	AbsURLPath string
}

Descriptor describes the needed publishing chain for an item.

type Fs

type Fs interface {
	Publish() afero.Fs
}

type Language

type Language interface {
	Location() *time.Location
	Collator() *collate.Collator
}

type LanguageConfig

type LanguageConfig interface {
	Name() string
	Code() string
}

type Publisher

type Publisher interface {
	Publish(d Descriptor) error
}

Publisher publishes a result file.

type Site

type Site interface {
	URL
	Language
}

type URL

type URL interface {
	AbsURL(in string) string
	RelURL(in string) string
	URLize(uri string) string
}

type URLConfig

type URLConfig interface {
	BaseUrl() string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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