Skip to content
This repository has been archived by the owner on Jul 6, 2021. It is now read-only.

Add support PostCSS extensions (.sss, .pcss, .postcss) #438

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/next-css/index.js
Expand Up @@ -13,7 +13,7 @@ module.exports = (nextConfig = {}) => {
const { cssModules, cssLoaderOptions, postcssLoaderOptions } = nextConfig

options.defaultLoaders.css = cssLoaderConfig(config, {
extensions: ['css'],
extensions: ['css', 'sss', 'pcss', 'postcss'],
cssModules,
cssLoaderOptions,
postcssLoaderOptions,
Expand All @@ -22,7 +22,7 @@ module.exports = (nextConfig = {}) => {
})

config.module.rules.push({
test: /\.css$/,
test: /\.(c|s|pc|postc)ss$/,
issuer(issuer) {
if (issuer.match(/pages[\\/]_document\.js$/)) {
throw new Error(
Expand Down