forked from Mirrors/bubbletea
Fix bug where extra blank line was being adding to output
This commit is contained in:
parent
72c1a1c0ef
commit
5ae602953c
2
tea.go
2
tea.go
|
@ -198,7 +198,7 @@ func (p *Program) Start() error {
|
||||||
|
|
||||||
// Render a view to the terminal. Returns the number of lines rendered.
|
// Render a view to the terminal. Returns the number of lines rendered.
|
||||||
func (p *Program) render(model Model, linesRendered int) int {
|
func (p *Program) render(model Model, linesRendered int) int {
|
||||||
view := p.view(model) + "\n"
|
view := "\n" + p.view(model)
|
||||||
|
|
||||||
// We need to add carriage returns to ensure that the cursor travels to the
|
// We need to add carriage returns to ensure that the cursor travels to the
|
||||||
// start of a column after a newline
|
// start of a column after a newline
|
||||||
|
|
Loading…
Reference in New Issue