mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-23 06:59:31 +01:00
fix: use showdown for markdown conversion
This commit is contained in:
@@ -18,7 +18,7 @@ function generateMetaTags(metadata, createMetaTag) {
|
||||
export function buildPage(
|
||||
template,
|
||||
createMetaTag,
|
||||
{ metadata, title, content, createdOn, editedOn }
|
||||
{ metadata, title, headline, content, createdOn, editedOn }
|
||||
) {
|
||||
let page = template;
|
||||
|
||||
@@ -29,6 +29,7 @@ export function buildPage(
|
||||
);
|
||||
|
||||
page = page.replace(/{{title}}/g, title);
|
||||
page = page.replace(/{{headline}}/g, headline);
|
||||
page = page.replace(/{{content}}/g, content);
|
||||
page = page.replace(/{{createdOn}}/g, formatDate(createdOn));
|
||||
page = page.replace(/{{editedOn}}/g, formatDate(editedOn));
|
||||
|
||||
@@ -5,11 +5,9 @@ const template = `<!DOCTYPE html>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
|
||||
<meta
|
||||
name="description"
|
||||
content="Notesnook is the most secure, zero-knowledge based, encrypted note-taking app all compiled into one simple to use package that works on all major platforms."
|
||||
content="{{headline}}"
|
||||
/>
|
||||
<title>{{title}} - Notesnook</title>
|
||||
<!-- DO NOT TOUCH THESE TAGS -->
|
||||
{{metaTags}}
|
||||
<title>{{title}} - Notesnook</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>{{title}}</h1>
|
||||
|
||||
@@ -1,10 +1,4 @@
|
||||
const template = `[//]: <> (DO NOT TOUCH THESE META TAGS)
|
||||
|
||||
{{metaTags}}
|
||||
|
||||
[//]: <> (METADATA TAGS END)
|
||||
|
||||
# {{title}}
|
||||
const template = `# {{title}}
|
||||
|
||||
{{content}}
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user