How does webpack print the requested interface information

webpack-dev-server proxy is used to solve the cross-domain problem in the process of using vue+webpack, in the project, but the address seen by each request interface is a local address, which is not convenient for debugging. How to print the requested interface information in the command window console?

devServer: {
        host:"192.168.1.230",
        disableHostCheck: true,
        proxy:[
            {
                context: ["/qd", "/logout"],
                target: "http://192.168.1.119:11000/psycholConsult/",
                secure: false,
                changeOrigin:true
            }
        ]
    },

Ah, what do you mean? If you want to debug, the devtool of the browser is enough, see what the console of the command window is doing


the owner of the question probably wants to print the actual address of the request on the console:
if you use axios, the http library, you can do something before sending the request

// 
axios.interceptors.request.use(function (config) {
    // 
    //  url
    console.log("real request url ==> ", config.url)
    return config;
  }, function (error) {
    // 
    return Promise.reject(error);
  });

// 
axios.interceptors.response.use(function (response) {
    // 
    
    return response;
  }, function (error) {
    // 
    return Promise.reject(error);
  });
Menu