سؤال

I'm experiencing a small problem writing a README.md for a project on http://github.com, apparently I'm not able to syntax highlight my code. This is the first time I write a README.md on Github (although I have some experience with markdown on other platforms) so my problem can be a very stupid mistake by my side.

Using http://github-preview.herokuapp.com/ and entering some simple markup taken directly from Github docs:

```ruby
require 'redcarpet'
markdown = Redcarpet.new("Hello World!")
puts markdown.to_html
```

I don't see syntax highlighting...

What am I doing wrong? Thanks for you your time

هل كانت مفيدة؟

المحلول

You would see the right syntax highlighting if you edit a README.md directly in your GitHub repo.

But the kei-s/github-preview project doesn't support all the features of GitHub Flavored Markdown.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top