Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Include CSS classname for language in syntax-highlighted code blocks #328

Closed
SLaks opened this issue Apr 13, 2016 · 5 comments
Closed
Assignees

Comments

@SLaks
Copy link

@SLaks SLaks commented Apr 13, 2016

RedCarpet includes class="language-blah" in the <code> tag for a syntax-highlighted code block with language specified.

This can be used to highlight and label code blocks by language, as I do in my blog.

I'd like to add this classname to Kramdown too.

SLaks pushed a commit to SLaks/kramdown that referenced this issue Apr 14, 2016
@gettalong
Copy link
Owner

@gettalong gettalong commented Apr 18, 2016

Currently the language-LANG part is removed when using a syntax highlighter. So the easiest way would be to just leave the information there. It would then be on the outermost <div> tag that surrounds the highlighted code which should't be a problem.

Would this solve your issue?

Loading

@gettalong gettalong self-assigned this Apr 18, 2016
@SLaks
Copy link
Author

@SLaks SLaks commented Apr 18, 2016

I did not realize that.
That should be fine too.

Loading

@gettalong gettalong closed this in 3d2b871 Apr 18, 2016
@SLaks
Copy link
Author

@SLaks SLaks commented Apr 18, 2016

Thanks!

Can you please release a version so I can get this in GitHub Pages?

Loading

@gettalong
Copy link
Owner

@gettalong gettalong commented Apr 18, 2016

In time, yes. But also not that Github Pages has its own release schedule.

Loading

@SLaks
Copy link
Author

@SLaks SLaks commented Apr 18, 2016

I know; after you release, I'll need to bug them to release. (once they switch to Kramdown on May 1st, I won't be able to push my blog until they release this)

Thanks again!

Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants