htmlWebpackPlugin.options.title code example

Example 1: htmlWebpackPlugin.options.title

//vue.config.js
module.exports = {
  chainWebpack: config => {
    config
      .plugin('html')
      .tap(args => {
        args[0].title = "Popular films";
        return args;
      })
  }
}

Example 2: vue htmlWebpackPlugin.options.title

// Put this into /vue.config.js
module.exports = {
  chainWebpack: config => {
    config
      .plugin('html')
      .tap(args => {
      args[0].title = '<Your new title>';	// Replace your title here
      return args;
    });
  }
};

Example 3: change htmlwebpackplugin.options.title

//vue.config.js
module.exports = {
    chainWebpack: config => {
        config
            .plugin('html')
            .tap(args => {
                args[0].title = "My Vue App";
                return args;
            })
    }
}