gatsby-plugin-s3
gatsby-plugin-s3 copied to clipboard
Add support for force and statusCode on redirects
According to the documentation for createRedirect, some plugins support the non-standard redirect parameters force
and statusCode
. It might be nice for us to support these too.
With Redirection Rules, we can support force
by adding/removing the HttpErrorCodeReturnedEquals: '404'
condition. We can support statusCode
by overriding the HttpRedirectCode
redirect value.
With redirect objects (#64) we can support force
by choosing whether to upload the content object or the redirect object in the event of a conflict. This would require a bit of a change to the upload logic. It's not possible to use redirect objects for anything other than 301, so they would have to still be handled by Redirection Rules.