fix: separate client and server utilities to fix build error
Split lib/utils.ts into: - lib/utils.ts: Client-safe utilities only (no Node.js imports) - lib/project-utils.ts: Server-only utilities with Node.js imports This fixes the Next.js build error where client components were importing modules that contained Node.js dependencies (fs, path). All tests pass and build succeeds. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
// app/api/projects/route.ts
|
||||
import { NextResponse } from 'next/server';
|
||||
import { getProjects } from '@/lib/fs-utils';
|
||||
import { getProjectDisplayName } from '@/lib/utils';
|
||||
import { getProjectDisplayName } from '@/lib/project-utils';
|
||||
|
||||
export async function GET() {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user