Closed onato closed 9 years ago
That bit of CSS is intentional. Sometimes you want highlighted code inline and the nowrap is necessary for that to work. The common way of displaying a larger block of code with multiple lines is to wrap <code></code>
with <pre>
.
I just added a demo syntax highlighting post showing all the ways you can add code to your Jekyll posts.
Personally I never write the HTML to do that manually and instead let MarkDown do the dirty work. But if that's what you're doing you'll want it to look something like this:
<pre>
<code>
// your code goes here
</code>
</pre>
Using the following in _base.scss causes lines of code to be put all on one line…