From 1cddbe656d7232c87af75af09a447a1d53f98f5b Mon Sep 17 00:00:00 2001 From: Marco Franssen Date: Fri, 28 Dec 2018 14:36:37 +0100 Subject: [PATCH] Add application/ld+json to posts and pages --- layout/common/article.ejs | 1 + layout/common/post/ld_json.ejs | 20 ++++++++++++++++++++ layout/plugin/google-analytics.ejs | 2 +- 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 layout/common/post/ld_json.ejs diff --git a/layout/common/article.ejs b/layout/common/article.ejs index 1b618897..a9a6946f 100644 --- a/layout/common/article.ejs +++ b/layout/common/article.ejs @@ -20,5 +20,6 @@ <%- partial('share/index', { post: post }) %> + <%- partial('post/ld_json', { post: post }) %> <%- partial('comment/index') %> diff --git a/layout/common/post/ld_json.ejs b/layout/common/post/ld_json.ejs new file mode 100644 index 00000000..f4922d92 --- /dev/null +++ b/layout/common/post/ld_json.ejs @@ -0,0 +1,20 @@ + \ No newline at end of file diff --git a/layout/plugin/google-analytics.ejs b/layout/plugin/google-analytics.ejs index 16636e4e..7725d88e 100644 --- a/layout/plugin/google-analytics.ejs +++ b/layout/plugin/google-analytics.ejs @@ -7,4 +7,4 @@ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) ga('create', '<%= theme.plugins.google_analytics %>', 'auto'); ga('send', 'pageview'); - \ No newline at end of file +