Skip to content

fix: Don't prevent rendering if buffer is empty#597

Open
mrjones2014 wants to merge 1 commit intoMeanderingProgrammer:mainfrom
mrjones2014:mrj/push-orlyosyrnnwt
Open

fix: Don't prevent rendering if buffer is empty#597
mrjones2014 wants to merge 1 commit intoMeanderingProgrammer:mainfrom
mrjones2014:mrj/push-orlyosyrnnwt

Conversation

@mrjones2014
Copy link

I think this: sudo-tee/opencode.nvim#200

Is actually a bug with this plugin.

If the text is non-empty, then is changed to empty via vim.api.nvim_buf_set_lines(buf, 0, -1, false, {}), render-markdown.nvim should still render in that case, otherwise it leaves behind some extmarks (I think those are extmarks)?

@MeanderingProgrammer
Copy link
Owner

This behavior is intentional and made to support LSP hover docs in older versions of neovim: 059f503

@mrjones2014
Copy link
Author

Hm okay interesting. Can you think of a different way to fix this issue?

Basically it leaves codeblock headers around if the buffer is cleared programmatically.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants