From 2881f8211aaaa2def3f3cedabf635f03733ac82e Mon Sep 17 00:00:00 2001 From: Erik Michelson Date: Fri, 4 Oct 2019 19:49:45 +0200 Subject: Added customizable og-metadata to notes Signed-off-by: Erik Michelson --- public/views/codimd/head.ejs | 4 ++++ public/views/pretty.ejs | 4 ++++ 2 files changed, 8 insertions(+) (limited to 'public/views') diff --git a/public/views/codimd/head.ejs b/public/views/codimd/head.ejs index e3edde66..e2f0375c 100644 --- a/public/views/codimd/head.ejs +++ b/public/views/codimd/head.ejs @@ -4,6 +4,10 @@ +<% for (var og in opengraph) { %> +<% if (opengraph.hasOwnProperty(og) && opengraph[og].trim() !== '') { %> + +<% }} %> <%= title %> diff --git a/public/views/pretty.ejs b/public/views/pretty.ejs index 1970ab2f..5f18ea8b 100644 --- a/public/views/pretty.ejs +++ b/public/views/pretty.ejs @@ -14,6 +14,10 @@ <% if(typeof description !== 'undefined' && description) { %> <% } %> + <% for (var og in opengraph) { %> + <% if (opengraph.hasOwnProperty(og) && opengraph[og].trim() !== '') { %> + + <% }} %> <%= title %> -- cgit v1.2.3