Home

Issue: 1754

Nested page component not re-rendered when data is updated

[issue link]

I have dynamic nested route /pages/users/_id.vue. I use asyncData to fetch the data from server.

  async asyncData ({ app, params }) {
    try {
      let { data } = await app.$axios.get(`/users/${params.id}`)
      console.log('data arrived')
      return { user: data.data }
    } catch (e) {
      console.log(e)
    }
  },
template>
  <div>
      <h3 class="semi-bold">
        {{ user.firstname) }} {{ user.lastname }}
      </h3>
   </div>
</template>

I navigate to localhost:3000/users/50 the page is rendered correctly. Then I navigate to other user page localhost:3000/users/567 the asyncData is executed and new user returned but the view is not re-rendered…

Is this a bug ?

This bug report is available on Nuxt.js community (#c1575)