From 4c41e477e13d37e187c8de4225c7e8056bd9ed28 Mon Sep 17 00:00:00 2001 From: Martin Kagamino Lehoux Date: Mon, 29 Sep 2025 19:17:13 +0200 Subject: Internalise theme --- config/postcss.config.js | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 config/postcss.config.js (limited to 'config/postcss.config.js') diff --git a/config/postcss.config.js b/config/postcss.config.js new file mode 100644 index 0000000..ee0749c --- /dev/null +++ b/config/postcss.config.js @@ -0,0 +1,21 @@ +const themeDir = __dirname + "/../"; + +const cssnanoPlugin = require("cssnano")({ + path: [themeDir], + preset: [ + "default", + { + discardComments: { + removeAll: true, + }, + }, + ], +}); + +module.exports = { + plugins: [ + require("tailwindcss")(themeDir + "./config/tailwind.config.js"), + require("autoprefixer")({ path: [themeDir] }), + ...(process.env.HUGO_ENVIRONMENT === "production" ? [cssnanoPlugin] : []), + ], +}; -- cgit v1.3