mirror of
https://git.ludikovsky.name/git/mdlive.git
synced 2024-05-16 18:35:27 +02:00
29 lines
709 B
HTML
29 lines
709 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>Live Markdown</title>
|
|
<meta charset="utf-8">
|
|
<script src="https://cdn.jsdelivr.net/jquery/2.2.3/jquery.min.js"></script>
|
|
</head>
|
|
<body>
|
|
<div id="input">
|
|
<textarea id="markdown" name="markdown" rows="25" cols="80"></textarea>
|
|
</div>
|
|
<div id="output"></div>
|
|
<script>
|
|
$('#input').change(
|
|
function(){
|
|
$.ajax({
|
|
url: "http://localhost:5000/parse",
|
|
success: function(result) {
|
|
$('#output').html(result);
|
|
},
|
|
data: { markdown: $('#markdown').val() },
|
|
type: 'POST'
|
|
});
|
|
}
|
|
);
|
|
</script>
|
|
</body>
|
|
</html>
|