Closed eneim closed 5 years ago
It is interesting enough that if I change this line to be
post.frontmatter.tags.indexOf(tag) !== -1
It will work normally as expected. Have no idea ...
@eneim Oh, yes... It's a bug... My fault... Of course the line should look like the one you wrote above ๐
Would you like to contribute? If yes, please create quick patch PR with this one-line fix ๐
@panr Done ๐
I observe that there will be this error when in
/src/posts/
folder you have more posts thanconfig.postsPerPage
value. What I have tried to reproduce this:Run below to load your starter unmodified,
Then copying the file
/src/posts/hello.md
tohello-2.md
,hello-3.md
etc (also change itspath
value to make sure each has different path), then runyarn build
for each copy.When the total number of posts in
/src/posts
exceeds 5 (defaultpostPerpage
),yarn build
will fail with the error below:If I change the
postPerPage
to be equal to or greater than total number of posts, it is Ok. Please take a look when you have time. Thanks.