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

94
Views
Uncaught TypeError: Cannot read properties of undefined (reading 'pathname'). How can I solve this issue?

[![enter image description here][1]][1]I'm using all latest version and styled components, This is my App.js file

import { BrowserRouter as Router, Route, Routes } from "react-router-dom";
    
function App() {
  return (
    <div className="App">
      <GlobalStyle/>
      <Router>
        <Navbar />
        <Routes>
          <Route path="/" exact element={<Hero />} />
          <Route path="/projects" exact element={<Projects />} />
          <Route path="/about" exact element={<About />} />
        </Routes>
      </Router>
    </div>
  );
}

Navbar.js

 {menuData.map((item, index) => {
              const border = index === menuData.length-1 ? '1px solid #fff':'none';
              const padding = index === menuData.length-1 ? '0 24px':'0';
              
              return (
                <NavItem key={index}>
                  <NavLinks to={item.link} style={{border, padding}}>
                    {item.title}
                  </NavLinks>
                </NavItem>
              )
            })}
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!