Prevent line breaks in wkhtmltopdf generated pdf -


i'm using wkhtmltopdf generate pdf files html templates. rest of stack flask jinja2 , pdfkit wrapper around wkhtmltopdf.

i need generate files containg code. there few long lines there, have break, fit page's width. wkhtmltopdf inserting \n (i think) @ end of each line.

i want have linebrakes without newline characters, allow users select whole code (few lines) , copy-paste 1 line. possible? how achieve it?

eg: <some-element attribute-number-one="having-very-long&boring-value" another-attribute="with-no-meaning-whatsoever"></some-element>

try copy-paste code above. should pasted 1 line, though it's displayed few lines. want achieve same effect in wkhtmltopdf-generated pdf files.


Comments