Skip to content

Commit

Permalink
Remove tailwind, was unused
Browse files Browse the repository at this point in the history
  • Loading branch information
danopia committed Jan 27, 2025
1 parent 2e021cc commit 89a6d91
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 349 deletions.
55 changes: 18 additions & 37 deletions build/react-frontend/config/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,6 @@ const imageInlineSizeLimit = parseInt(
// Check if TypeScript is setup
const useTypeScript = fs.existsSync(paths.appTsConfig);

// Check if Tailwind config exists
const useTailwind = fs.existsSync(
path.join(paths.appPath, 'tailwind.config.js')
);

// Get the path to the uncompiled service worker (if it exists).
const swSrc = paths.swSrc;

Expand Down Expand Up @@ -131,36 +126,22 @@ module.exports = function (webpackEnv) {
// https://github.com/facebook/create-react-app/issues/2677
ident: 'postcss',
config: false,
plugins: !useTailwind
? [
'postcss-flexbugs-fixes',
[
'postcss-preset-env',
{
autoprefixer: {
flexbox: 'no-2009',
},
stage: 3,
},
],
// Adds PostCSS Normalize as the reset css with default options,
// so that it honors browserslist config in package.json
// which in turn let's users customize the target behavior as per their needs.
'postcss-normalize',
]
: [
'tailwindcss',
'postcss-flexbugs-fixes',
[
'postcss-preset-env',
{
autoprefixer: {
flexbox: 'no-2009',
},
stage: 3,
},
],
],
plugins: [
'postcss-flexbugs-fixes',
[
'postcss-preset-env',
{
autoprefixer: {
flexbox: 'no-2009',
},
stage: 3,
},
],
// Adds PostCSS Normalize as the reset css with default options,
// so that it honors browserslist config in package.json
// which in turn let's users customize the target behavior as per their needs.
'postcss-normalize',
],
},
sourceMap: isEnvProduction ? shouldUseSourceMap : isEnvDevelopment,
},
Expand Down Expand Up @@ -419,7 +400,7 @@ module.exports = function (webpackEnv) {
},
],
],

plugins: [
isEnvDevelopment &&
shouldUseReactRefresh &&
Expand Down Expand Up @@ -453,7 +434,7 @@ module.exports = function (webpackEnv) {
cacheDirectory: true,
// See #6846 for context on why cacheCompression is disabled
cacheCompression: false,

// Babel sourcemaps are needed for debugging into node_modules
// code. Without the options below, debuggers like VSCode
// show incorrect code and set breakpoints on the wrong lines.
Expand Down
1 change: 0 additions & 1 deletion build/react-frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@
"semver": "^7.6.3",
"source-map-loader": "^5.0.0",
"style-loader": "^4.0.0",
"tailwindcss": "^3.4.17",
"terser-webpack-plugin": "^5.3.11",
"webpack": "^5.97.1",
"webpack-dev-server": "^5.2.0",
Expand Down
Loading

0 comments on commit 89a6d91

Please sign in to comment.