Skip to content

Commit

Permalink
Updated webpack configs
Browse files Browse the repository at this point in the history
  • Loading branch information
pookmish committed Oct 19, 2023
1 parent 2ef1fa9 commit 1c25af6
Show file tree
Hide file tree
Showing 5 changed files with 887 additions and 733 deletions.
2 changes: 1 addition & 1 deletion themes/soe_basic/dist/css/components.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion themes/soe_basic/dist/css/theme.css

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions themes/soe_basic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,17 @@
"license": "ISC",
"dependencies": {
"@babel/core": "^7.22.1",
"@babel/polyfill": "^7.12.1",
"@babel/preset-env": "^7.22.4",
"autoprefixer": "^10.4.16",
"babel-loader": "^9.1.2",
"css-loader": "^6.8.1",
"decanter": "^6.2.14",
"drupal-behaviors-loader": "^1.0.1",
"element-closest-polyfill": "^1.0.6",
"element-matches-polyfill": "^1.0.0",
"element-qsa-scope": "^1.1.0",
"es6-object-assign": "^1.1.0",
"filemanager-webpack-plugin": "^8.0.0",
"mini-css-extract-plugin": "^2.7.6",
"node-sass": "^9.0.0",
Expand Down
11 changes: 10 additions & 1 deletion themes/soe_basic/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ const MiniCssExtractPlugin = require("mini-css-extract-plugin");
const OptimizeCSSAssetsPlugin = require("optimize-css-assets-webpack-plugin");
const FixStyleOnlyEntriesPlugin = require("webpack-fix-style-only-entries");
const FileManagerPlugin = require('filemanager-webpack-plugin');
const autoprefixer = require('autoprefixer')({ grid: true });

const config = {
isProd: process.env.NODE_ENV === "production",
Expand Down Expand Up @@ -61,7 +62,15 @@ var webpackConfig = {
use: [
config.isProd ? { loader: MiniCssExtractPlugin.loader } : 'style-loader',
{loader:'css-loader', options: {}},
{loader:'postcss-loader', options: {}},
{
loader: 'postcss-loader',
options: {
postcssOptions: {
sourceMap: true,
plugins: [autoprefixer],
},
}
},
{loader:'sass-loader', options: {}}
]
},
Expand Down
Loading

0 comments on commit 1c25af6

Please sign in to comment.