Skip to content

Add CI check for unique redirect URLs #1

Closed
@bvaughn

Description

@bvaughn

@sophiebits and I recently noticed that /docs/index.html redirected to /docs/accessibility.html rather than /docs/hello-world.html. This turned out to be because both /docs/hello-word.md and /docs/accessibility.md declared the redirect rule redirect_from: "docs/index.html". (Presumably this is because one was copied from the other without much thought about the redirect bit.)

We should add a check to gatsby-node.js that throws an error if it detects a duplicate redirect. This will cause the Netlify preview to fail and alert a PR reviewer that there's a problem.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions