Documentation ¶ Index ¶ type Model func NewModel(opts ModelOpts) *Model func (m *Model) Init() tea.Cmd func (m *Model) Update(msg tea.Msg) (tea.Model, tea.Cmd) func (m *Model) View() string type ModelOpts Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type Model ¶ type Model struct { // contains filtered or unexported fields } Model holds the state of the application. func NewModel ¶ func NewModel(opts ModelOpts) *Model NewModel returns a new Model configured with the given ModelOpts. func (*Model) Init ¶ func (m *Model) Init() tea.Cmd Init initializes the application. It focuses on the selector element. func (*Model) Update ¶ func (m *Model) Update(msg tea.Msg) (tea.Model, tea.Cmd) Update handles messages. func (*Model) View ¶ func (m *Model) View() string View returns the view for this model. If the application is zoomed on the output window then just the output window and footer are rendered. Otherwise, all of the windows are rendered, with the unfocused windows shown with a faint style. type ModelOpts ¶ type ModelOpts struct { Selector string Output string Path string LineNumbers bool Wrap bool } ModelOpts defines the options that can be set on a Model. Source Files ¶ View all Source files item.gomodel.go Click to show internal directories. Click to hide internal directories.