-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
[gatsby-plugin-sitemap] Documentation and DX improvements #29810
Comments
Sounds great 👍 Thanks for tackling this and a PR is welcome! But you should also know that we have a pending PR for this plugin rewrite: #25670 |
Ahhh, thanks for letting me know. I'll watch out for the release and check it out. Thanks! |
Hiya! This issue has gone quiet. Spooky quiet. 👻 We get a lot of issues, so we currently close issues after 60 days of inactivity. It’s been at least 20 days since the last update here. Thanks for being a part of the Gatsby community! 💪💜 |
I've still got my eye on this, waiting for the next version to be published |
looks like that PR you were waiting on is stale? #25670 |
@arun-is It looks like they're still working on getting it through |
#25670 was merged and currently published under the |
Summary
I implemented gatsby-plugin-sitemap onto my site just now, and I ran into a few problems that I think could've been prevented by improving documentation and adding some error handling with logging in the plugin.
First, I was unclear that it is required to query
allSitePage
with apath
property. The docs do state this, however as devs do, we typically skim documentation. Would be good to add error handling/logging when theallSitePage
option is missing.Second, I forgot to return from the
serialize
function, which led to this error. I think this could be improved with some error handling. If urls is undefined, throw an error with a message "gatsby-plugin-sitemap did not recieve sitemap entries. Did you forget to return from your serialize function". Or something of that nature.Motivation
To improve DX when implementing the sitemap plugin
Steps to resolve this issue
I will be cooking up a pull request for your consideration to resolve these issues 👍
The text was updated successfully, but these errors were encountered: