mirror of
https://github.com/rooyca/obsidian-api-request.git
synced 2026-07-22 07:50:27 +00:00
parent
50e0c29932
commit
64d587deba
1 changed files with 0 additions and 3 deletions
|
|
@ -2,9 +2,6 @@
|
|||
|
||||
export class MarkdownParser {
|
||||
parse(text) {
|
||||
// Remove all <script> tags
|
||||
text = text.replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi, '');
|
||||
|
||||
// Headers
|
||||
text = text.replace(/^(#{1,6})\s*(.*)$/gm, (match, p1, p2) => `<h${p1.length}>${p2}</h${p1.length}>`);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue