model

package
v0.0.0-...-90a12ec Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Article

type Article struct {
	PublishedAt time.Time         `json:"publishedAt"`
	Extra       map[string]string `json:"extra,omitempty"`
	Body        string            `json:"body"`
	Summary     string            `json:"summary"`
	Title       string            `json:"title"`
	Slug        string            `json:"slug"`
	Tags        []string          `json:"tags"`
	IsPublished bool              `json:"isPublished"`
}

func (*Article) OpenGraphData

func (a *Article) OpenGraphData() OpenGraphData

func (*Article) SafeURL

func (a *Article) SafeURL() templ.SafeURL

func (*Article) URL

func (a *Article) URL() string

type ContextData

type ContextData struct {
	BuildTime           string
	BundledStaticAssets []byte
	Debug               bool
	IsPartial           bool
}

type OpenGraphData

type OpenGraphData struct {
	Title       string
	Description string
	Image       string
	Type        string
}

type PageData

type PageData struct {
	Search     string
	Tag        string
	Items      []*Article
	TotalPages int
	Page       int
	PerPage    int
}

Jump to

Keyboard shortcuts

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