adjust bubble tea mod

This commit is contained in:
Preston Baxter 2024-02-10 22:23:15 -06:00
parent da49e8f86a
commit 14c9ee8b4d
3 changed files with 12 additions and 2 deletions

4
go.mod
View File

@ -1,6 +1,6 @@
module github.com/charmbracelet/bubbletea module git.preston-baxter.com/Preston_PLB/bubbletea
go 1.18 go 1.21
require ( require (
github.com/containerd/console v1.0.4-0.20230313162750-1ae8d489ac81 github.com/containerd/console v1.0.4-0.20230313162750-1ae8d489ac81

View File

@ -223,3 +223,9 @@ func WithFPS(fps int) ProgramOption {
p.fps = fps p.fps = fps
} }
} }
func WithRenderer(renderer Renderer) ProgramOption {
return func(p *Program) {
p.renderer = renderer
}
}

View File

@ -1,5 +1,9 @@
package tea package tea
type Renderer interface {
renderer
}
// renderer is the interface for Bubble Tea renderers. // renderer is the interface for Bubble Tea renderers.
type renderer interface { type renderer interface {
// Start the renderer. // Start the renderer.