fix: 🐛 Fix `md` with newline

This commit is contained in:
Kainoa Kanter 2022-03-23 15:53:06 -07:00 committed by GitHub
parent 807aa1f516
commit e863421fae
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -130,7 +130,7 @@ function viewPaste(content: string, views: string) {
for (let i = 1; i <= content.split("\n").length; i++) {
lineNumbers.innerHTML = lineNumbers.innerHTML + `${i}<br>`
}
if (content.startsWith("---") || content.startsWith("md ")) {
if (content.startsWith("---") || content.startsWith("md ") || content.startsWith("md\n")) {
codeView.innerHTML = marked.parse(content.substring(3))
hide(lineNumbers)
} else {