一、将图片放至根目录
二、修改根目录中index.html文件
<link rel="icon" href="image/x-icon" href="./logo1.png">
三、修改根目录build下面webpack.dev.conf.js和webpack.prod.conf.js
webpack.dev.conf.js和webpack.prod.conf.js都在HtmlWebpackPlugin中添加
favicon: path.resolve('logo1.png')