Closed csic21 closed 1 year ago
Hi @csic21 this is how Gatsby works. You'll need to run a build again in order to update the static files with the latest data. During development source-wordpress runs a server that does this for you.
In a production site you will typically set up webhooks from WPGatsby settings in wp-admin to trigger your CI service that builds your site. Locally you can run gatsby build
again and refresh the page and you should see updated content. As long as you don't run gatsby clean
the build should be relatively quick. Let me know if you have any other questions.
Preliminary Checks
Description
When using
gatsby develop
, adding an article using wordpress can be dynamically generated. But when usinggatsby build
+gatsby serve
, adding a new article with wordpress only has the old data. Does the production environment not support the function of dynamically generating articles? Do I need to rebuild every time I write an article in wordpress?Reproduction Link
https://github.com/gatsbyjs/gatsby/tree/master/starters/gatsby-starter-wordpress-blog
Steps to Reproduce
use wordpress official Starter
Expected Result
Use
gatsby serve
to automatically get wordpress articles.like use plugin gatsby-source-wordpress options nodeUpdateInterval ingatsby-config.js
Actual Result
Unable to automatically update articles using gatsby serve
Environment
Config Flags
No response