Closed chrissearle closed 10 years ago
What does your layout look like?
Now that was a good hint. I'd totally forgotten that I was using haml there (and yes - now I feel stupid).
If you didn't know already, ~
in Haml is the same as running find_and_preserve
, so just switch your =
to ~
I've just found https://github.com/middleman/middleman-syntax/issues/16 - which shows the symptom I have exactly. However it (as well as a fair few other hits on the net) all end up being about how HAML is doing the indenting - and the fix seems to be haml config.
However - I'm not using haml.
My content files are title.html.md.erb
Config for markdown er
Markdown engine is kramdown (1.3.3). Have also tested with redcarpet 3.1.1.
What I see is that if there are two or more lines in a fenced code section (see e.g. this source document - for both ruby and sql blocks) then in the built HTML I see nicely indented HTML generated from the markdown - which of course breaks the code layout by adding those spaces when inside a pre block. The example article renders like this
I'd appreciate any ideas on how to fix this :)