chainWebpack – how to set infrastructureLogging

I have chainWebpack section in vue.config.js. I

chainWebpack: config => {
    // Add "node_modules" alias
    config.resolve.alias
        .set('node_modules', path.join(__dirname, './node_modules'));

    config.devtool('source-map');
    // Do not remove whitespaces
    config.module.rule('vue')
        .use('vue-loader')
        .loader('vue-loader')
        .tap(options => {
            options.compilerOptions.preserveWhitespace = true
            return options
        })
}

I want to include infrastructureLogging section to redirect logging to stdout instead of stderr:

module.exports = {
  //...
  infrastructureLogging: {
    stream: process.stdout,
  },
};

How can i do that in using chainWebpack section?

Source: Ask Javascript Questions

LEAVE A COMMENT