-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
[proposal] suggest render repo description by markdown language #13412
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
Conversation
Signed-off-by: a1012112796 <[email protected]>
Codecov Report
@@ Coverage Diff @@
## master #13412 +/- ##
==========================================
- Coverage 42.11% 42.09% -0.03%
==========================================
Files 691 691
Lines 76003 75999 -4
==========================================
- Hits 32010 31993 -17
- Misses 38744 38759 +15
+ Partials 5249 5247 -2
Continue to review full report at Codecov.
|
} | ||
return template.HTML(markup.Sanitize(string(desc))) | ||
func (repo *Repository) DescriptionHTML() string { | ||
return string(markdown.Render([]byte(repo.Description), repo.HTMLURL(), repo.ComposeMetas())) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think markup.RenderDescriptionHTML
has done that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I'm fine with allowing single-line markdown-rendered content there but I'm not sure if we want to allow multi-line stuff, as that could destroy our layout. |
I think since only one line allowed currently, the requirement for the description to render as markdown is little. |
mark it as a draft because I'm not sure it's necessay, it's just a proposal, waiting more responses, thanks.