Skip to content

Commit 83e7e64

Browse files
Axel Bockflypenguin
Axel Bock
authored andcommitted
add optional <hr> element before comments
1 parent f6cce07 commit 83e7e64

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,7 @@ Comments is disabled by default. Enable comments in your `.Site.Params`.
193193
[params]
194194
[params.comments]
195195
enabled = true
196+
insert_hr_line = false # inserts an <hr> element before comment block
196197
engine = "disqus" # default if unset
197198
# other options: disqus, utterances, cactus_comments, remark42
198199
```

layouts/partials/comments.html

+2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
{{ $enable_comments := .Scratch.Get "enable_comments" }}
22
{{ if $enable_comments -}}
3+
{{- if .Site.Params.Comments.insert_hr_line -}}<hr/>
4+
{{ end -}}
35
<div class="blog-post-comments">
46
{{ if (or (not (isset .Site.Params.Comments "engine")) (eq .Site.Params.Comments.Engine "disqus")) }}
57
{{ partial "comments/disqus.html" . }}

0 commit comments

Comments
 (0)