Commit 1c60c3d73dfe9b12729a2d5339f12a34f31cf3f4
Exists in
master
and in
4 other branches
Merge pull request #1147 from miks/master
Add automatic HTML id attributes to markdown headings to allow linking to content sections in wiki
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
app/helpers/application_helper.rb
| @@ -43,7 +43,7 @@ module ApplicationHelper | @@ -43,7 +43,7 @@ module ApplicationHelper | ||
| 43 | end | 43 | end |
| 44 | 44 | ||
| 45 | def markdown(text) | 45 | def markdown(text) |
| 46 | - @__renderer ||= Redcarpet::Markdown.new(Redcarpet::Render::GitlabHTML.new(filter_html: true), { | 46 | + @__renderer ||= Redcarpet::Markdown.new(Redcarpet::Render::GitlabHTML.new({ filter_html: true, with_toc_data: true }), { |
| 47 | no_intra_emphasis: true, | 47 | no_intra_emphasis: true, |
| 48 | tables: true, | 48 | tables: true, |
| 49 | fenced_code_blocks: true, | 49 | fenced_code_blocks: true, |