Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

208
Vistas
Why can't I navigate to the detail page when I'm using a link component in react

In react, I want to use this code to link the detail page in my main list page. This is the react code:

{
      title: 'more',
      render: (val, row) => {
            return (<Link to={`/zhuolian/activity/detail/${row.id}`}>more...</Link>);
      },
    },

and this is my route config:

{
        path: '/zhuolian',
        name: 'zhuolian',
        icon: 'contacts',
        routes:[
          {
            path: '/zhuolian/activity',
            name: 'activity',
            hideChildrenInMenu: true,
            component: './xRepo/Activity',
            routes:[
              {
                path: '/zhuolian/activity/detail/:activityId',
                name: 'detail',
                component: './xRepo/Activity/detail',
              },
            ]
          },
          
        ]
      },

I am now using the router version "react-router-dom": "^4.3.1", and when I click on more, the log shows this warning:

index.js:1 Warning: Hash history cannot PUSH the same path; a new entry will not be added to the history stack

and it did not navigate to the detail page. I have tried to add the replace in the link component but it still did not work. Am I missing something? What should I do to make it link to another detail page when I click more?

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda