feat: WordCount
This commit is contained in:
22
layout/_partial/post/word.ejs
Normal file
22
layout/_partial/post/word.ejs
Normal file
@@ -0,0 +1,22 @@
|
||||
<% if (!theme.word_count.only_article_visit || (!index && theme.word_count.only_article_visit)){ %>
|
||||
<div style="margin-top:10px;">
|
||||
<span class="post-time">
|
||||
<span class="post-meta-item-icon">
|
||||
<!-- fonts.scss -->
|
||||
<!-- 百度字体平台:http://fontstore.baidu.com/static/editor/index.html -->
|
||||
<i class="icon-statistics"></i>
|
||||
<span class="post-meta-item-text"> 字数统计:</span>
|
||||
<span class="post-count"><%= wordcount(post.content) %>字</span>
|
||||
</span>
|
||||
</span>
|
||||
|
||||
<span class="post-time">
|
||||
|
|
||||
<span class="post-meta-item-icon">
|
||||
<i class="icon-book icon"></i>
|
||||
<span class="post-meta-item-text"> 阅读时长≈</span>
|
||||
<span class="post-count"><%= min2read(post.content) %>分</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<% } %>
|
Reference in New Issue
Block a user