Feel-ix-343/markdown-oxide

Formatting does not accept nested Todos

Closed this issue · 1 comments

Hello!

Love the LSP! Use it all the time for Obsidian and it works great for almost everything.

I have format on save in my Nvim config right now, and I had to disable that for markdown files because it causes my nested Todos to be broken into multiple lines.

So if I have something like this:

- [ ] Some todo
   - [ ] A nested todo

The formatting will add a line break between my todos (and even move the todo back a little, but not fully).

It will end up something like this:

- [ ] Some todo

 - [ ] A nested todo

EDIT: That will not happen if I have more todos underneath that. Or if I have multiple nested layers.
Like so:

- [ ] Some todo
   - [ ] A nested todo
- [ ] Another todo

EDIT2: What an edge case, apparently, it needs to have another todo further down to "draw" the todo from it's parent:

This will cause it to happen:

- [ ] Some todo
   - [ ] A nested todo

- [ ] Another todo

Hey! Thanks for reporting.

Unfortunately I don't think I'll be able to help with this as markdown-oxide doesn't provide any formatting features - or any special support for todos for that matter.

I hope you figure it out!

I'll close this for now too