server

package
v0.0.0-...-88ca17d Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRouter

func NewRouter(logger *slog.Logger) (*echo.Echo, error)

func ToAsciiCast

func ToAsciiCast(stdout string, writer io.Writer) error

For backward compatibility.

Types

type AsciiCastConverter

type AsciiCastConverter struct {
	// Version is the version of the asciicast format
	Version int
	// TerminalWidth is the width of the terminal in columns
	TerminalWidth int
	// TerminalHeight is the height of the terminal in rows
	TerminalHeight int
	// LinesPerChunk controls how many lines we group together in a single event
	LinesPerChunk int
	// ChunkSpeedDivisor controls how the chunk size affects timing
	ChunkSpeedDivisor float64
	// MinTimeIncrement is the minimum time between events in seconds
	MinTimeIncrement float64
	// MaxTimeIncrement is the maximum time between events in seconds
	MaxTimeIncrement float64
}

AsciiCastConverter handles the conversion of text output to asciicast format.

func NewAsciiCastConverter

func NewAsciiCastConverter() *AsciiCastConverter

NewAsciiCastConverter creates a new converter with default settings.

func (*AsciiCastConverter) ToAsciiCast

func (c *AsciiCastConverter) ToAsciiCast(stdout string, writer io.Writer) error

ToAsciiCast converts a string of stdout to asciicast format and writes it to the given writer.

type TemplateRender

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

func (*TemplateRender) Render

func (t *TemplateRender) Render(w io.Writer, name string, data interface{}, c echo.Context) error

Jump to

Keyboard shortcuts

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