[Vuejs]-How to integrate Node.js running on different port with Vue.js running on a different port altogether?

0👍

The easiest way would be to use webpack-dev-server proxy option to proxy requests from webpack-dev-server (8080) to Node (3000).

Example config:

{
  devServer: {
    proxy: {
      '/api': {
        target: 'http://127.0.0.1:3000'
      }
    }
  }
}

Leave a comment