feed

package
v0.0.0-...-59ecffa Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package feed renders the items of a site and serves them.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Feeds

type Feeds struct {
	RSS  string
	Atom string
	JSON string
}

Feeds holds the formats of one site as they are served.

func Render

func Render(site config.Site, items []scrape.Item) (*Feeds, error)

Render builds all three formats at once, so a site is either published completely or not at all.

type Store

type Store struct {
	// contains filtered or unexported fields
}

Store holds the feeds of one site. The whole set is swapped at once, so a reader never sees a half updated site and no lock is needed to read.

func (*Store) Atom

func (s *Store) Atom() http.HandlerFunc

func (*Store) JSON

func (s *Store) JSON() http.HandlerFunc

func (*Store) Publish

func (s *Store) Publish(rendered *Feeds)

func (*Store) RSS

func (s *Store) RSS() http.HandlerFunc

Jump to

Keyboard shortcuts

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