My current project is using Scss
in combination with Bootstrap
for design. I have implemented purgeCss
to remove unused Css
, and customized my postcss.config.js
file as follows:
module.exports = {
plugins: [
"postcss-flexbugs-fixes",
[
"postcss-preset-env",
{
autoprefixer: {
flexbox: "no-2009",
},
stage: 3,
features: {
"custom-properties": false,
},
},
],
[
"@fullhuman/postcss-purgecss",
{
content: [
"./pages/**/*.{js,jsx,ts,tsx}",
"./components/**/*.{js,jsx,ts,tsx}",
],
defaultExtractor: (content) => content.match(/[\w-/:]+(?<!:)/g) || [],
safelist: ["html", "body"],
},
],
],
};
However, I encountered an issue where postCss
is not recognizing my Scss
files and therefore not displaying the styles properly.
How can I include Scss
in the postcss.config.js
file?