Home

Issue: 1832

asyncData ssr

[issue link]

here is my question.
in page component pages/index.vue i have such code

  asyncData () {
    return axios.get('/api/articles')
      .then(({ data: { docs, total } }) => {
        return { list: docs, total }
      })
  },

and here is nuxt.config.js

  modules: [
    '@nuxtjs/axios',
    '@nuxtjs/proxy'
  ],
  proxy: [
    ['/api', { target: 'http://localhost:7001' }]
  ],

when i open localhost:3000 ,i get error, the error msg is here

NuxtServerError

connect ECONNREFUSED 127.0.0.1:80

Why?

This question is available on Nuxt.js community (#c1648)