From 22c6ee74194093426e14cd1cbdfd82c4d175103c Mon Sep 17 00:00:00 2001 From: Steve Date: Mon, 28 Jan 2019 16:12:13 -0500 Subject: Fix htmlEscaped chars in json output for lunr Both .Title and .Summary output modified with `plainify | htmlUnescape` to remove escaped chars. --- layouts/index.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/index.json b/layouts/index.json index 52b514b..14b2184 100644 --- a/layouts/index.json +++ b/layouts/index.json @@ -1,5 +1,5 @@ {{- $.Scratch.Add "index" slice -}} {{- range where .Site.Pages ".Params.skip" "ne" "true" -}} -{{- $.Scratch.Add "index" (dict "uri" .Permalink "title" (cond (eq .Site.Params.titlecase true) (.Title | title | markdownify) (.Title | markdownify)) "categories" .Params.categories "keywords" .Params.keywords "content" .Summary) -}} +{{- $.Scratch.Add "index" (dict "uri" .Permalink "title" (cond (eq .Site.Params.titlecase true) (.Title | title | markdownify | htmlUnescape) (.Title | markdownify | htmlUnescape)) "categories" .Params.categories "keywords" .Params.keywords "content" (.Summary | plainify | htmlUnescape )) -}} {{- end -}} {{- $.Scratch.Get "index" | jsonify -}} -- cgit v1.2.3