md

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2026 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package md renders the yomi-shape Markdown archive: a plain-text mirror of the repository that reads naturally, greps, and diffs (spec §10). The repository home is README.md; each tweet is md/<id>.md and each reconstructed thread is threads/<root>.md. Markdown derives from the same stored records as the HTML site, so the two views always agree (TP3). Output is deterministic — no clock, no map iteration in the text — so golden tests run with no network.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Renderer

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

Renderer builds the Markdown views over one repository's records and media.

func New

func New(tweets []*x.Tweet, assets []repo.Asset, profile *x.User, footer, title string) *Renderer

New builds a Markdown renderer. footer carries the capture stamp; title is the repository display name used in the README heading.

func (*Renderer) Index

func (r *Renderer) Index(threads []thread.Thread, heading, subheading string) string

Index renders README.md: the profile header (when captured) followed by a reverse-chronological list of captured threads, each linking to its Markdown page. heading/subheading label a non-profile capture.

func (*Renderer) Thread

func (r *Renderer) Thread(th thread.Thread) string

Thread renders a reconstructed conversation for threads/<root>.md.

func (*Renderer) Tweet

func (r *Renderer) Tweet(t *x.Tweet) string

Tweet renders one tweet as a standalone Markdown document for md/<id>.md.

Jump to

Keyboard shortcuts

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