Simple redirection rules and HTTP404 handling #177
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I'm sure there's a better way to handle this ...
I wanted to implement some redirection rules for dead pages and HTTP404 handling. I haven't figured out how to set statuscode=404 which is needed
See
./AppRouter/redirectionRules
which defines redirection rulesAnd
App()
which processes redirection usingHttp404 handling is done later on in App() where I have some dodgy logic which needs reviewing
basically
which inserts in between the app top bar and footer OR the page content depending on if the URL is recognised or not
There's probably a better way to do this using React Router and
<Route path="*">
however I wanted to hide the side menu bar when HTTP404 is detected