mirror of
https://github.com/next-theme/hexo-theme-next.git
synced 2026-01-20 19:02:33 +00:00
Add changyan count configuration (#570)
This commit is contained in:
parent
c53fd12292
commit
1d7daf7480
@ -610,6 +610,8 @@ changyan:
|
|||||||
enable: false
|
enable: false
|
||||||
appid:
|
appid:
|
||||||
appkey:
|
appkey:
|
||||||
|
# Show comments count
|
||||||
|
count: true
|
||||||
|
|
||||||
# LiveRe comments system
|
# LiveRe comments system
|
||||||
# You can get your uid from https://livere.com/insight/myCode (General web site)
|
# You can get your uid from https://livere.com/insight/myCode (General web site)
|
||||||
|
|||||||
@ -19,7 +19,7 @@ hexo.extend.filter.register('theme_inject', injects => {
|
|||||||
// Add post_meta
|
// Add post_meta
|
||||||
hexo.extend.filter.register('theme_inject', injects => {
|
hexo.extend.filter.register('theme_inject', injects => {
|
||||||
const config = hexo.theme.config.changyan;
|
const config = hexo.theme.config.changyan;
|
||||||
if (!config.enable || !config.appid || !config.appkey) return;
|
if (!config.enable || !config.count || !config.appid || !config.appkey) return;
|
||||||
|
|
||||||
injects.postMeta.raw('changyan', `
|
injects.postMeta.raw('changyan', `
|
||||||
{% if post.comments %}
|
{% if post.comments %}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user