Visual editor adds unwanted line breaks in source text

I am writing text using the source editor in Rstudio (2022.07.1) in an Rmarkdown (2.17) document. I sometimes switch to the Visual editor to create a table or to add a reference. Visual editor then adds line breaks in my text which I don't want.

I went to the settings and even with 'Soft-wrap R Markdown files' and 'Automatic text wrapping (line breaks)' unselected, it still does it.

How can I prevent this behavior?

1 Like

I noticed that in the YAML header there was this option included automatically:

    wrap: 72

Which I didn't select. Changing that to

    wrap: none

Fixed the problem.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.