ch264 / json-gatsby-wordpress-graphql

POC for headless blog and Gatsby
MIT License
0 stars 0 forks source link

Update create page call for blog posts in nodeJS to use multiple calls #35

Open mclausaudio opened 4 years ago

mclausaudio commented 4 years ago

wpgraphql only returns 100 items at a time. Since we have over 100 posts, every post older than the 100th isn't getting created. This is the same issue we had for tags. If there are more blog posts remaining we'll need to make additional calls.

Once the function I'm using for multiple 'tags' calls is made reusable, cleaned up and 'DRYer', use it for blog posts too.