Skip to content

feat: add redirects for DSG pages #102

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

Merged
merged 2 commits into from
Mar 28, 2022
Merged

feat: add redirects for DSG pages #102

merged 2 commits into from
Mar 28, 2022

Conversation

orinokai
Copy link
Contributor

Summary

Ensure that SSR and DSG pages are redirected to the appropriate handler function. Previously, only SSR pages were redirected and DSG pages were picked up by a catch-all redirect in netlify/netlify-plugin-gatsby that was also inadvertently handling 404 pages.

Test plan

  1. Build and deploy the demo in netlify/netlify-plugin-gatsby, ensuring that DSG is enabled in the post.js template
  2. During the build, before the netlify.toml is reverted, ensure that /blog/[slug] routes are individually redirected to the handler function

Relevant links (GitHub issues, Notion docs, etc.) or a picture of cute animal

See also netlify/netlify-plugin-gatsby#334

Standard checks:

  • Check the Deploy Preview's Demo site for your PR's functionality
  • Add docs when necessary

🧪 Once merged, make sure to update the version if needed and that it was published correctly.

@orinokai orinokai self-assigned this Mar 25, 2022
@github-actions github-actions bot added the type: feature code contributing to the implementation of a feature and/or user facing functionality label Mar 25, 2022
Copy link
Contributor

@ericapisani ericapisani left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

Copy link
Contributor

@ascorbic ascorbic left a comment

Choose a reason for hiding this comment

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

Looking good!

@kodiakhq kodiakhq bot merged commit 3efa580 into main Mar 28, 2022
@kodiakhq kodiakhq bot deleted the rs/dsg-redirects branch March 28, 2022 10:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge type: feature code contributing to the implementation of a feature and/or user facing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants