HTML code script for Markdown to HTML
Created on 3 July, 2024 • 115 views
HTML code script for Markdown to HTML
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Blog Post</title>
<script src="https://github.com/showdownjs"></script>
</head>
<body>
<h1>My Blog Post</h1>
<div id="markdown-content"></div>
<script>
// Replace this with your actual Markdown content
const markdownText = "# This is a heading\n* This is a list item\n[Link Text](https://www.example.com)";
const converter = new showdown.Converter();
const html = converter.makeHtml(markdownText);
document.getElementById("markdown-content").innerHTML = html;
</script>
</body>
</html>
Popular posts
-
HTML script for Bulk URL Opener• 192 views
-
HTML code script for a Signature generator• 160 views
-
HTML code script for a HTML tags remover• 150 views
-
HTML code script for a Safe URL checker• 140 views
-
HTML code scrip for Whirlpool generator• 124 views