mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
move docs, remove katex
This commit is contained in:
1 parent
da6002278d
commit
c4a13f2e27
27 files changed
+190
-550
No files matched your search
@@ -103,10 +103,11 @@ class SwitchLanguageHandler extends Handler {
|
||||
}
|
||||
|
||||
class MarkdownHandler extends Handler {
|
||||
async post({ text, safe = true }) {
|
||||
this.response.body = safe
|
||||
? markdown.safe.render(text)
|
||||
: markdown.unsafe.render(text);
|
||||
async post({ text, html = false, inline = false }) {
|
||||
this.response.body = inline
|
||||
? markdown.renderInline(text, html)
|
||||
: markdown.render(text, html);
|
||||
this.response.type = 'text/html';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user