title: How can i create 404 Page Not Found in react-router-dom V5
body: <p>I use <code>react-router-dom</code> V5. When I create <code>Route</code> component in my project I use <code>&lt;HashRouter&gt;</code>.</p>
  <p>This is example of my component:</p>
  <pre><code>&lt;HashRouter&gt;
    &lt;Switch&gt;
      &lt;Route path=&quot;/form&quot; component={Login} /&gt;
      &lt;Route path=&quot;/admin&quot; component={Panel} /&gt;
      &lt;Route path=&quot;/changepass&quot; component={ChangePass} /&gt;
      &lt;Route path=&quot;*&quot; component={NotFound} /&gt;
    &lt;/Switch&gt;
  &lt;/HashRouter&gt;
  </code></pre>
  <p>For example when I enter: <code>&quot;/akfakafk&quot;</code> it works correctly, but when I enter: <code>&quot;/admin/wtwtwtw&quot;</code> it's not working.</p>
  <p>I know it is not implemented correctly,</p>
  <p><strong>I want to know, how can I implement this?</strong></p>
  <p>By the way in <code>&quot;/admin&quot;</code> render <code>Panel</code> component that has return  another routes.</p>
  <p>This is my  panel routes:</p>
  <pre><code>const dashboardRoutes = [
    {
      path: &quot;/dashboard&quot;,
      name: dashboard,
      icon: DashboardIcon,
      component: DashboardPage,
      layout: &quot;/admin&quot;,
    },
    {
      path: &quot;/devicesManagement&quot;,
      name: devicesManagement,
      icon: DevicesIcon,
      component: DevicesPage,
      layout: &quot;/admin&quot;,
    }
  ]
  </code></pre>