Fix issue with sass-loader options

This commit is contained in:
Giuseppe Digilio
2020-12-07 14:28:57 +01:00
parent 5db5e0978a
commit eed458569f

View File

@@ -1,8 +1,7 @@
import { buildRoot, globalCSSImports, projectRoot, theme, themedTest, themedUse, themePath } from './helpers'; import { buildRoot, globalCSSImports, projectRoot, themedTest, themedUse, themePath } from './helpers';
const CopyWebpackPlugin = require('copy-webpack-plugin'); const CopyWebpackPlugin = require('copy-webpack-plugin');
const path = require('path'); const path = require('path');
const fs = require('fs');
const HtmlWebpackPlugin = require('html-webpack-plugin'); const HtmlWebpackPlugin = require('html-webpack-plugin');
const ScriptExtPlugin = require('script-ext-html-webpack-plugin'); const ScriptExtPlugin = require('script-ext-html-webpack-plugin');
@@ -65,8 +64,10 @@ export const commonExports = {
loader: 'sass-loader', loader: 'sass-loader',
options: { options: {
sourceMap: true, sourceMap: true,
sassOptions: {
includePaths: [projectRoot('./'), path.join(themePath, 'styles')] includePaths: [projectRoot('./'), path.join(themePath, 'styles')]
} }
}
}, },
{ {
loader: 'sass-resources-loader', loader: 'sass-resources-loader',
@@ -90,9 +91,11 @@ export const commonExports = {
loader: 'sass-loader', loader: 'sass-loader',
options: { options: {
sourceMap: true, sourceMap: true,
sassOptions: {
includePaths: [projectRoot('./'), path.join(themePath, 'styles')] includePaths: [projectRoot('./'), path.join(themePath, 'styles')]
} }
} }
}
] ]
}, },
], ],