OliverBalfour / obsidian-pandoc

Pandoc document export plugin for Obsidian (https://obsidian.md)
MIT License
719 stars 60 forks source link

Line break behavior exporting to Latex #189

Closed nmariano9 closed 1 year ago

nmariano9 commented 1 year ago

Hello: this might be more of an issue with Pandoc than the Obsidian plugin, but I want to inquire if there's a workaround for this. When I export from markdown to Latex, the resulting file will have new line breaks at each individual line (seemingly where each line ends visually on the markdown document). This is as opposed to the desired behavior of having each paragraph on a single line.

Represented visually in Overleaf, this is the desired result, and what you would naturally get working natively in Overleaf -- each paragraph on a single "line":

image

This is what you get if you export the same text from Markdown and open in Overleaf -- a new line break after each "line":

image

This makes no difference to how the document looks when it is knitted to PDF in Overleaf. However, it makes subsequent editing of the text in a Latex editor much more difficult & seems like an overall suboptimal behavior. Any way to fix?

nmariano9 commented 1 year ago

Found the solution to this: include "--wrap=preserve" in "Extra Pandoc arguments."