Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

130
Views
React descendant routes

I'm trying to implement a <Routes> element inside another <Routes> element, but it doesn't seem to be working. I followed the official tutorial here but it's not working for some reason.

Here is my code:

App:

class App extends Component {
    render(){
       return (
          <div className='App'>
             <Routes>
                 <Route path="/" element={<HomePage/>} />
                 <Route path="/pricing" element={ <PricingPage/> } />
                 <Route path="/signup" element={< SignupPage/> } />
                 <Route path="/login" element={< LoginPage/> } />
                 <Route path="/dashboard/*" element={ <Dashboard/> } />
             </Routes>
          </div>
       );
     }
   }

Dashboard:

export class Dashboard extends Component{

render(){
    return(
        <div className="Dashboard">
            <DashboardHeader/>
            <DashboardContainer/>
            <Routes>
                <Route link="/" element={<DashboardHome/>}/>
                <Route link="/subscribers" element={<DashboardSubscribers/>}/>
            </Routes>
        </div>
    );
}
}

I've tried everything but nothing seems to work. Console doesn't return any errors.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!