Skip to content

setup react router 4#15

Merged
ayshadogo merged 2 commits intoDfunder:mainfrom
EDOHWARES:feature/setup-react-router-4
Mar 1, 2026
Merged

setup react router 4#15
ayshadogo merged 2 commits intoDfunder:mainfrom
EDOHWARES:feature/setup-react-router-4

Conversation

@EDOHWARES
Copy link
Copy Markdown
Contributor

Description

This PR addresses issue #4 by setting up React Router v6 and defining all top-level application routes centrally.

Changes Made

  • Installed react-router-dom dependency.
  • Created AppRouter.jsx to configure the <BrowserRouter> and define application-wide routing.
  • Set up a nested MainLayout using <Outlet /> for consistent navigation and page structure.
  • Created placeholder page components for all core routes:
    • Home (/)
    • Explore (/explore)
    • CreateCampaign (/create)
    • CampaignDetails (/campaign/:id)
    • Dashboard (/dashboard)
    • Admin (/admin)
    • Login (/login)
    • Register (/register)
    • NotFound (*) - Handles 404s.
  • Cleaned up App.jsx to render the router instance instead of placeholder boilerplate.

Related Issues

Closes #4

Type of Change

  • New feature (non-breaking change which adds functionality)

Acceptance Criteria Met

  • All defined routes navigate correctly.
  • Unmapped routes navigate directly to the NotFound (404) page component.
  • The react-router-dom has been properly installed and integrated.

@ayshadogo
Copy link
Copy Markdown
Contributor

Nice work

Thank you for your Contribution 🤝

@ayshadogo ayshadogo merged commit 801dd20 into Dfunder:main Mar 1, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Setup React Router

2 participants