Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pagination only works on pathPrefix/2 and break on pathPrefix #45

Closed
ajmalafif opened this issue Jul 15, 2019 · 1 comment
Closed

Pagination only works on pathPrefix/2 and break on pathPrefix #45

ajmalafif opened this issue Jul 15, 2019 · 1 comment

Comments

@ajmalafif
Copy link

Hi,

I am not sure if gatsby-paginate is the root cause but I narrowed down that the pagination somehow works on pathPrefix/2 but not no posts are listed on pathPrefix.

Here's my gatsby-node.js: https://github.com/ajmalafif/ajmalafif.com/blob/master/gatsby-node.js

Here's the pathPrefix/2 page that works somehow: https://5d2cb8dae6f14b0007f00f14--ajmalafif.netlify.com/journal/2
Here's the broken page: https://5d2cb8dae6f14b0007f00f14--ajmalafif.netlify.com/journal/

I am getting this 404 in console but I am not sure how and where to fix this.

I keep trying things out on gatsby-node.js on createPaginatedPages and I'm not sure if I'm looking at the right place to solve this.

@aswinckr
Copy link

I think the pages created from your markdowns on your pages folder is overriding the pageContext prop. Try removing your journal folder from pages directory and move it outside ( remember to edit gatsby-config to modify your file-system-plugin to point to the new directory )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants