From 78eb3d5844dd8bad05d8b375955a978aa5f988c8 Mon Sep 17 00:00:00 2001
From: Thibaud Colas <thibaudcolas@gmail.com>
Date: Tue, 18 Apr 2023 15:32:05 +0100
Subject: [PATCH] Always set Sass output to expanded so CSS process is
 identical in dev and prod builds (#10347)

---
 client/webpack.config.js | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/client/webpack.config.js b/client/webpack.config.js
index 1a0dfe51ab..4462125180 100644
--- a/client/webpack.config.js
+++ b/client/webpack.config.js
@@ -232,7 +232,17 @@ module.exports = function exports(env, argv) {
                 },
               },
             },
-            'sass-loader',
+            {
+              loader: 'sass-loader',
+              options: {
+                sassOptions: {
+                  // Manually set Sass output so it’s identical in production and development. See:
+                  // https://github.com/tailwindlabs/tailwindcss/issues/11027
+                  // https://github.com/webpack-contrib/sass-loader/issues/1129
+                  outputStyle: 'expanded',
+                },
+              },
+            },
           ],
         },
       ].concat(