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

365
Vistas
How can ı do vue 3 compositon api router refresh page

After confirming in vue 3 compositon api

router.push('/IssueList');

Here, I want my and components to refresh when they come to the IssueList page.

I'm redirecting to the page, but it doesn't refresh the issuelist page. How can I do that?

The codes on my IssueList page are as follows.

<template>
  <div>
    <div class="card">
      
      <h5>Konu Listesi</h5>
      <Button label="Yeni Konu Oluştur" class="p-button-success p-button-outlined mb-2" icon="pi pi-plus"
              @click="newIssue"></Button>
      <TabView ref="tabview1">
        <TabPanel header="Bana Gelenler">
          <issue-incoming></issue-incoming>
        </TabPanel>
        <TabPanel header="Benim Yazdıklarım">
          <issue-send  ></issue-send>
        </TabPanel>
      </TabView>
    </div>
  </div>

</template>
about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

if i understand your question correctly you should tie a :key value pair to the component you want to refresh. so essentially when whatever happens in the example function it will increment the change variable which is tied to the component and forces it to refresh.

example -

    <template>
  <div>
   <div @click="example()"> <p>update</p> </div>
    <Component :key="change" />
  </div>
</template>

<script>
import { ref } from "vue";
export default {
  components: {
    Component,
  },
  setup() {
    var change = ref(0);

    function example() {
      
        change.value += 1;
      
    }

    return {
      change,
      example,
    };
  },
};
</script>
about 4 years ago · Juan Pablo Isaza Denunciar
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