Assist_Design/apps/portal/next.config.mjs
barsa d9734b0c82 Enhance Signup Workflow and Update Catalog Components
- Refactored the SignupWorkflowService to throw a DomainHttpException for legacy account conflicts, improving error handling.
- Updated the SignupForm component to include initialEmail and showFooterLinks props, enhancing user experience during account creation.
- Improved the AccountStep in the SignupForm to allow users to add optional details, such as date of birth and gender, for a more personalized signup process.
- Enhanced the PasswordStep to include terms acceptance and marketing consent options, ensuring compliance and user engagement.
- Updated various catalog views to improve layout and user guidance, streamlining the onboarding process for new users.
2025-12-22 18:59:38 +09:00

51 lines
1.4 KiB
JavaScript

import path from "node:path";
import { fileURLToPath } from "node:url";
const __dirname = path.dirname(fileURLToPath(import.meta.url));
const workspaceRoot = path.resolve(__dirname, "..", "..");
/** @type {import('next').NextConfig} */
const nextConfig = {
output: process.env.NODE_ENV === "production" ? "standalone" : undefined,
turbopack: {
resolveAlias: {
"@customer-portal/domain": path.join(workspaceRoot, "packages/domain/dist"),
},
},
webpack(config) {
config.resolve.alias = {
...config.resolve.alias,
"@customer-portal/domain": path.join(workspaceRoot, "packages/domain/dist"),
};
return config;
},
env: {
NEXT_PUBLIC_API_BASE: process.env.NEXT_PUBLIC_API_BASE,
NEXT_PUBLIC_APP_NAME: process.env.NEXT_PUBLIC_APP_NAME,
NEXT_PUBLIC_APP_VERSION: process.env.NEXT_PUBLIC_APP_VERSION,
},
compiler: {
removeConsole: process.env.NODE_ENV === "production",
},
experimental: {
optimizePackageImports: ["@heroicons/react", "@tanstack/react-query"],
},
typescript: { ignoreBuildErrors: false },
};
// Only load bundle analyzer when explicitly requested
let exportedConfig = nextConfig;
if (process.env.ANALYZE === "true") {
const bundleAnalyzer = (await import("@next/bundle-analyzer")).default;
exportedConfig = bundleAnalyzer({ enabled: true })(nextConfig);
}
export default exportedConfig;