Skip to content

Commit

Permalink
refactor: Remove unnecessary sass-loader compat
Browse files Browse the repository at this point in the history
  • Loading branch information
rschristian committed Dec 14, 2022
1 parent ef58367 commit f291e6c
Showing 1 changed file with 6 additions and 14 deletions.
20 changes: 6 additions & 14 deletions packages/cli/src/lib/webpack/webpack-base-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,19 +45,6 @@ function resolveTsconfig(cwd, isProd) {
}
}

function getSassConfiguration(...includePaths) {
const config = {
sourceMap: true,
sassOptions: {
includePaths,
},
};

Object.defineProperty(config, 'includePaths', { value: includePaths });

return config;
}

/**
* @param {import('../../../types').Env} env
* @returns {import('webpack').Configuration}
Expand Down Expand Up @@ -185,7 +172,12 @@ module.exports = function createBaseConfig(config, env) {
options: {
cwd,
loader: tryResolveOptionalLoader('sass-loader'),
options: getSassConfiguration(...nodeModules),
options: {
sourceMap: true,
sassOptions: {
includePaths: [...nodeModules],
},
},
},
},
],
Expand Down

0 comments on commit f291e6c

Please sign in to comment.