Skip to content

Commit

Permalink
Merge pull request #103 from newfold-labs/fix-utilities-css-minification
Browse files Browse the repository at this point in the history
Fix minification using postcss detection of env
  • Loading branch information
zlateska authored Aug 22, 2024
2 parents 5cc3801 + dd3dfe3 commit f041134
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions postcss.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
const tailwind = require("./tailwind.config");
const { resolve } = require("path");

module.exports = () => ({
module.exports = (ctx) => ({
ident: "postcss",
sourceMap: process.env.NODE_ENV !== "production",
sourceMap: ctx.env !== "production",
plugins: [
require("tailwindcss")({
...tailwind,
Expand All @@ -18,7 +18,7 @@ module.exports = () => ({
});
},
require("autoprefixer")({ grid: true }),
process.env.NODE_ENV === "production" &&
ctx.env === "production" &&
require("cssnano")({
preset: [
"default",
Expand Down

0 comments on commit f041134

Please sign in to comment.