From 014abc2903fabdd26783a2b6c0ad7d3590c1bd20 Mon Sep 17 00:00:00 2001 From: dranc Date: Wed, 3 Jan 2024 22:24:27 +0100 Subject: [PATCH] fix paths --- config/webpack.common.js | 17 ++--------------- src/asset/html/index.html | 6 +++--- 2 files changed, 5 insertions(+), 18 deletions(-) diff --git a/config/webpack.common.js b/config/webpack.common.js index b1f0280..8a78181 100644 --- a/config/webpack.common.js +++ b/config/webpack.common.js @@ -2,7 +2,6 @@ const SizePlugin = require('size-plugin'); const CopyWebpackPlugin = require('copy-webpack-plugin'); -const MiniCssExtractPlugin = require('mini-css-extract-plugin'); const PATHS = require('./paths'); @@ -25,12 +24,6 @@ const common = { }, module: { rules: [ - // Help webpack in understanding CSS files imported in .js files - { - test: /\.css$/, - use: [MiniCssExtractPlugin.loader, 'css-loader'], - }, - // Check for images imported in .js files and { test: /\.(png|jpe?g|gif)$/i, use: [ @@ -51,16 +44,10 @@ const common = { // Copy static assets from `public` folder to `build` folder new CopyWebpackPlugin({ patterns: [ - { - from: '**/*', - context: 'src/asset', - }, + { from: 'html', to: '', context: 'src/asset' }, + { from: 'icons/*', context: 'src/asset' }, ] }), - // Extract CSS into separate files - new MiniCssExtractPlugin({ - filename: '[name].css', - }), ], }; diff --git a/src/asset/html/index.html b/src/asset/html/index.html index 3c3543b..67fe68b 100644 --- a/src/asset/html/index.html +++ b/src/asset/html/index.html @@ -1,11 +1,11 @@ - + @@ -32,6 +32,6 @@ - +