diff --git a/package.json b/package.json index af1057a..d95b1d1 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "@babel/preset-env": "^7.20.2", "babel-loader": "^9.1.2", "css-loader": "^6.7.3", + "file-loader": "^6.2.0", "html-webpack-plugin": "^5.5.0", "install": "^0.13.0", "mini-css-extract-plugin": "^2.7.2", diff --git a/src/images/favicon.png b/src/images/favicon.png new file mode 100644 index 0000000..1c64735 Binary files /dev/null and b/src/images/favicon.png differ diff --git a/webpack.config.js b/webpack.config.js index 9f1c2d5..1659db5 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -27,12 +27,17 @@ module.exports = { } } }, + { + test: /\.(png|jpg)$/i, + use: 'file-loader', + }, ] }, plugins: [ new HtmlWebpackPlugin({ - template: './src/index.html', title: 'Rock Paper Scissor', + favicon: './src/images/favicon.png', + template: './src/index.html', }), new MiniCssExtractPlugin(), ]