Issue #7 🎫: 404 not found page (component) and HashRouter migration #12
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.
Pull Request Summary for Issue #7 Completion
Overview:
Changes Made:
Added:
/src/components/pages/NotFoundPage.tsx
FloatingAstronaut
animation component./src/styles/pages/notFoundPage.scss
NotFoundPage
component.Modified:
.eslintrc.json
no-undef
set tooff
for all .ts and .tsx files./src/index.tsx
BrowserRouter
toHashRouter
to fix the issue with the 404 page not being rendered when the user navigates to a non-existing path on the deployed version using GitHub Pages (gh-pages)./src/App.tsx
NotFoundPage
component when the path does not match any routes at the root level, i.e/
./src/App.tsx
/src/components/UI/AnimatedButton.tsx
/src/components/UI/FileTabsNavbar.tsx
/src/components/UI/Navbar.tsx
/src/components/pages/AboutPage.tsx
/src/components/pages/AccessPage.tsx
/iturres-reactive-portfolio/
prefix from all URL paths./src/components/pages/HomePage.tsx
NotFoundPage
component when the path does not match any of the routes at the home page level onwards, i.e/homepage
./src/styles/UI/button.scss
.static-shadow
to style theNotFoundPage
button. This class can also be used to style other buttons.Deleted:
/public/404.html
404.html
file from the/public
directory since it is no longer being used.Reasoning:
The
NotFoundPage
will be rendered in two different scenarios:/
i.e the Access page, the button will display the text "Go back to the Access Page" and redirect the user to the/
path./homepage
path.Impact:
NotFoundPage
will be rendered and the user can go back to the About page or the Access page, improving the user experience.Testing:
Related Issues:
Dependencies:
Additional Notes:
The 'going back' to the About page in the
NotFoundPage
button text and redirecting the user to the/homepage
path, is a bit misleading. I will open a new issue to address this.A new deployment has been triggered to update with all these new changes the live version of the portfolio.
You can see here v2.0.0 - Migrate to HashRouter.