editor.go
1package repl
2
3import tea "github.com/charmbracelet/bubbletea"
4
5type editorCmp struct{}
6
7func (i *editorCmp) Init() tea.Cmd {
8 return nil
9}
10
11func (i *editorCmp) Update(_ tea.Msg) (tea.Model, tea.Cmd) {
12 return i, nil
13}
14
15func (i *editorCmp) View() string {
16 return "Editor"
17}
18
19func NewEditorCmp() tea.Model {
20 return &editorCmp{}
21}