forked from cory/tildefriends
Slight wiki formatting tweaks.
git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4636 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
parent
edabd7735c
commit
a3cca9aae6
@ -1,5 +1,5 @@
|
||||
{
|
||||
"type": "tildefriends-app",
|
||||
"emoji": "📝",
|
||||
"previous": "&UMb81rZg54kgoGBmpGBtWcmtuioPfTx6HT3OyQYJ/LU=.sha256"
|
||||
"previous": "&LCMT+xWf3xEYwQ7HLx9AUHuj0wTHOn2Ux0uUz8Anlu4=.sha256"
|
||||
}
|
@ -2,9 +2,9 @@ import * as utils from './utils.js';
|
||||
import * as commonmark from './commonmark.min.js';
|
||||
|
||||
function markdown(md) {
|
||||
var reader = new commonmark.Parser({safe: true});
|
||||
var writer = new commonmark.HtmlRenderer();
|
||||
var parsed = reader.parse(md || '');
|
||||
let reader = new commonmark.Parser({safe: true});
|
||||
let writer = new commonmark.HtmlRenderer();
|
||||
let parsed = reader.parse(md || '');
|
||||
let walker = parsed.walker();
|
||||
let event;
|
||||
while ((event = walker.next())) {
|
||||
@ -55,7 +55,7 @@ async function main() {
|
||||
await respond({
|
||||
data: `
|
||||
<h1>${wiki_name}: ${wiki_doc_name}</h1>
|
||||
<pre>${markdown(md)}</pre>
|
||||
<div>${markdown(md)}</div>
|
||||
`,
|
||||
content_type: 'text/html',
|
||||
status_code: 200,
|
||||
|
Loading…
Reference in New Issue
Block a user