Skip to content

Commit 9441640

Browse files
committed
fix: data utils for blogpost pages
1 parent 207b4ea commit 9441640

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/utils/dataUtils.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,10 @@ export const fetchAllBlogPosts = async () => {
2323
const processedPosts = [];
2424
allPostsData.forEach((item) => {
2525
if (item.series) {
26-
item.series.posts.forEach((seriesPost) => {
26+
item.series.posts.forEach((seriesPost, index) => {
2727
processedPosts.push({
2828
...seriesPost,
29+
seriesIndex: index + 1,
2930
filename: seriesPost.filename.startsWith('/')
3031
? seriesPost.filename.substring(1)
3132
: seriesPost.filename,

0 commit comments

Comments
 (0)