gabrielelana / vim-markdown

Markdown for Vim: a complete environment to create Markdown files with a syntax highlight that doesn't suck!
MIT License
740 stars 59 forks source link

Support inline code blocks inside text #1

Closed andreapavoni closed 10 years ago

andreapavoni commented 10 years ago

Hi Gabriele,

as already asked on twitter, it would be very helpful to have support for inline code blocks with backticks. Example:

This is a text with SomeCode inline.

Screenshot of what I usually get: vimshot

As you can see, it's very annoying :-(

gabrielelana commented 10 years ago

It should be already supported, can you install the plugin and try? If you get something that you think is wrong then attach the markdown file and a screenshot and I’ll fix it right away :smile:

BTW: The Markdown specification only supports single and double back ticks, triple back ticks are an extension and they should be used for fenced code blocks not for inline code

this is some inline `code`

also this is inline ``code``

```ruby
# this is a block of ruby code


**But** Github supports **any** number of back ticks as inline code delimiter and since my goal is to mirror the Github behaviour… your example should be rendered as you expect

Let me know
andreapavoni commented 10 years ago

Thank you Gabriele! Shame on me I've never checked the right syntax :P It works as you explained (and I went over the code blocks in my articles to fix them).