Skip to content

Commit 617f9c7

Browse files
committed
Allow comment replies to be disabled
Add a mode to "lock" comments by setting lock_comments in the page configuration.
1 parent 5640349 commit 617f9c7

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

_config.yml

+1
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ defaults:
7676
type: posts
7777
values:
7878
comments: true
79+
lock_comments: false
7980
- scope:
8081
path: tags
8182
values:

_includes/comments.html

+4
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,17 @@ <h2>Comments</h2>
1919
</div>
2020
{% endif %}
2121

22+
{% if page.lock_comments != true %}
2223
<!-- New comment form -->
2324
<div id="respond" class="comment__new">
2425
{% include comment_form.html %}
2526
</div>
27+
{% endif %}
2628
</section>
2729

30+
{% if page.lock_comments != true %}
2831
<script src="{{ '/assets/main.js' | relative_url }}"></script>
2932
{% if site.reCaptcha.enabled %}
3033
<script src="https://www.google.com/recaptcha/api.js"></script>
3134
{% endif %}
35+
{% endif %}

0 commit comments

Comments
 (0)