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

feat: improved sitemap #3579

Merged
merged 8 commits into from
Jun 16, 2022
Merged

feat: improved sitemap #3579

merged 8 commits into from
Jun 16, 2022

Conversation

alextim
Copy link
Contributor

@alextim alextim commented Jun 12, 2022

Changes

@astrojs/sitemap

  • Split up large sitemap into multiple sitemaps by custom limit. This functionality is provided by sitemap pkg.
  • Ability to add sitemap specific attributes: priority, hangefreq and lastmod.
  • serialize option: final output customization via JS function.
  • Localization support.
  • All config options are validated by zod.

@example/integrations-playground

fix: site option is added to astro.config

@changeset-bot
Copy link

changeset-bot bot commented Jun 12, 2022

🦋 Changeset detected

Latest commit: 5e2356b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@astrojs/sitemap Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added pkg: example Related to an example package (scope) pkg: integration Related to any renderer integration (scope) labels Jun 12, 2022
@alextim alextim changed the title Feat/sitemap feat: improved sitemap Jun 13, 2022
Copy link
Member

@natemoo-re natemoo-re left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks really great! Just concerned about how the automatic link injection is handled.

packages/integrations/sitemap/src/process-pages.ts Outdated Show resolved Hide resolved
@alextim
Copy link
Contributor Author

alextim commented Jun 15, 2022

Done:

  • 'createLinkInHead' logic and its deps - removed;
  • README - updated;
  • some refactoring for cleaner code;
  • tested locally.

Copy link
Member

@natemoo-re natemoo-re left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🙌🏻 This is incredible! Thanks so much for contributing all of these awesome changes back upstream!

Copy link
Contributor

@tony-sull tony-sull left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh wow, this is excellent! Nice work on the thorough docs, logging, and config validation 👍

Ship it! 🚀

@tony-sull tony-sull merged commit 1031c06 into withastro:main Jun 16, 2022
@github-actions github-actions bot mentioned this pull request Jun 16, 2022
@alextim
Copy link
Contributor Author

alextim commented Jun 16, 2022

Many thanks for your kind words.
It's not completely finished on my side. Hope to continue.

@gabrielpaivadev
Copy link

Thank you so much @alextim

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: example Related to an example package (scope) pkg: integration Related to any renderer integration (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants