/**
 * PostCSS configuration
 */
const config = {
  plugins: [require("postcss-import"), require("@tailwindcss/postcss")],
};

// Add more modules to production
if (process.env.APP_ENV === "production") {
  config.plugins.push(
    require("cssnano")({ preset: "default" }),
    require("autoprefixer"),
    require("postcss-nested"),
    require("postcss-flexbugs-fixes"),
  );
}

// Export config file
module.exports = config;
