.preformatted {
    white-space: pre-wrap;

<div class="preformatted">
    <= no spaces there, before
    pasting this text in this code ;
    It should render with its
    own formatting.

Emacs indentation actually adds (8) spaces in front of each line.

If I manually remove those indentation spaces, and quickly save the file, it works, and the div is rendered correctly.

But as soon as the indentation kicks in again, the div is rendered with each line starting with 8 spaces. NB yes, I tend to prefer spaces for indenting my code.


How can I tell Emacs to (please) not touch my content?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.