File tree 4 files changed +17
-7
lines changed
4 files changed +17
-7
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ group :jekyll_plugins do
7
7
gem "jekyll-paginate"
8
8
gem "jekyll-redirect-from"
9
9
gem "jekyll-seo-tag" , "~> 2.6.1"
10
+ gem "jekyll-archives"
10
11
end
11
12
12
13
group :test do
Original file line number Diff line number Diff line change @@ -161,7 +161,6 @@ defaults:
161
161
label : Home
162
162
url : /
163
163
164
-
165
164
sass :
166
165
sass_dir : /assets/css
167
166
style : compressed
@@ -198,3 +197,13 @@ sitemap_exclude: # Sitemap will exclude the following items.
198
197
- sitemap.xml
199
198
- robots.txt
200
199
- redirects.json
200
+
201
+ # see: <https://github.com/jekyll/jekyll-archives/blob/master/docs/configuration.md>
202
+ jekyll-archives :
203
+ enabled : [categories, tags]
204
+ layouts :
205
+ category : category
206
+ tag : tag
207
+ permalinks :
208
+ tag : ' /tags/:name/'
209
+ category : ' /categories/:name/'
Original file line number Diff line number Diff line change 10
10
< h1 class ="pl-lg-2 ">
11
11
< i class ="far fa-folder-open fa-fw text-muted "> </ i >
12
12
{{ page.title }}
13
- < span class ="lead text-muted pl-2 "> {{ site.categories[ page.category] | size }}</ span >
13
+ < span class ="lead text-muted pl-2 "> {{ page.posts | size }}</ span >
14
14
</ h1 >
15
15
16
16
< ul class ="post-content pl-0 ">
17
- {% for post in site.categories[ page.category] %}
17
+ {% for post in page.posts %}
18
18
< li class ="d-flex justify-content-between pl-md-3 pr-md-3 ">
19
19
< a href ="{{ post.url | relative_url }} "> {{ post.title }}</ a >
20
20
< span class ="dash flex-grow-1 "> </ span >
21
21
< span class ="text-muted small "> {{ post.date | date: site.data.date_format.post.long }}</ span >
22
22
</ li >
23
23
{% endfor %}
24
24
</ ul >
25
- </ div >
25
+ </ div >
Original file line number Diff line number Diff line change 11
11
< h1 class ="pl-lg-2 ">
12
12
< i class ="fa fa-tag fa-fw text-muted "> </ i >
13
13
{{ page.title }}
14
- < span class ="lead text-muted pl-2 "> {{ site.tags[ page.tag] | size }}</ span >
14
+ < span class ="lead text-muted pl-2 "> {{ page.posts | size }}</ span >
15
15
</ h1 >
16
16
< ul class ="post-content pl-0 ">
17
- {% for post in site.tags[ page.tag] %}
17
+ {% for post in page.posts %}
18
18
< li class ="d-flex justify-content-between pl-md-3 pr-md-3 ">
19
19
< a href ="{{ post.url | relative_url }} "> {{ post.title }}</ a >
20
20
< span class ="dash flex-grow-1 "> </ span >
21
21
< span class ="text-muted small "> {{ post.date | date: site.data.date_format.post.long }}</ span >
22
22
</ li >
23
23
{% endfor %}
24
24
</ ul >
25
- </ div >
25
+ </ div >
You can’t perform that action at this time.
0 commit comments