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

225
Views
nuxt.js get data from vuex with axios
computed: {
  msgs_id() {
    return this.$store?.state?.get_dir[`${this.$route.params.id}`]['id']
  }
},

async asyncData({ $axios }) {
  try {
    const direct = await $axios.$get(`/chat/messages/40`)
    return { direct }
  } catch (error) {
    console.log(error)
  }
}

When I type the id 40 manually it returns data, but when I return it from the computed it does not return data

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!