File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ const orderedPosts = posts.sort((a, b) => {
1414})
1515
1616orderedPosts .forEach ((post , index ) => {
17- if (post .slug === activeSlug ) {
17+ if (post .id === activeSlug ) {
1818 if (posts [index - 1 ]) {
1919 prev = posts [index - 1 ]
2020 }
@@ -32,7 +32,7 @@ orderedPosts.forEach((post, index) => {
3232 {
3333 prev && (
3434 <a
35- href = { ` /blog/${prev .slug } ` }
35+ href = { ` /blog/${prev .id } ` }
3636 rel = " prefetch"
3737 class = " flex border items-center rounded-md w-full my-1 md:my-0 content-center justify-start md:justify-start p-4 hover:border-blue-300 hover:shadow-sm dark:border-slate-700"
3838 title = { ` Previous: ${prev .data .title } ` }
@@ -49,7 +49,7 @@ orderedPosts.forEach((post, index) => {
4949 {
5050 next && (
5151 <a
52- href = { ` /blog/${next .slug } ` }
52+ href = { ` /blog/${next .id } ` }
5353 rel = " prefetch"
5454 class = " flex border items-center rounded-md w-full my-1 md:my-0 content-center justify-start md:justify-end md:text-right p-4 hover:border-blue-300 hover:shadow-sm dark:border-slate-700"
5555 title = { ` Next: ${next .data .title } ` }
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ const items = recentPosts.map((post) => {
3939 postContent += ensureAbsoluteUrls ( marked . parse ( post . body ) )
4040
4141 return {
42- link : `${ blogUrl } /${ post . slug } ` ,
42+ link : `${ blogUrl } /${ post . id } ` ,
4343 title : post . data . title ,
4444 description : post . data . summary ,
4545 categories : post . data . categories ,
You can’t perform that action at this time.
0 commit comments