14a32bdc0d
- Unified monorepo with backend (Express), frontend (Next.js), and devops - Backend: ESLint, Prettier, Jest tests (3 passing), health endpoint, .env.example - Frontend: Fixed build errors, fixed all lint errors (0 remaining), tests passing - DevOps: Docker Compose with PostgreSQL, backend, frontend + healthchecks - CI/CD: 3 GitHub Actions workflows (backend, frontend, docker integration) - DX: Husky pre-commit hooks with smart change detection - Docs: Root README with architecture, CONTRIBUTING.md, PR template Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
28 lines
765 B
TypeScript
28 lines
765 B
TypeScript
"use client";
|
|
|
|
import { useState, useEffect } from "react";
|
|
import { DashboardLayout } from "@/components/layouts/DashboardLayout";
|
|
import { WebsiteSettings } from "@/components/dashboard/WebsiteSettings";
|
|
|
|
export default function WebsiteSettingsPage(props: any) {
|
|
const [id, setId] = useState<string | null>(null);
|
|
|
|
useEffect(() => {
|
|
const resolveParams = async () => {
|
|
try {
|
|
const params = await Promise.resolve(props?.params);
|
|
setId(params?.id || null);
|
|
} catch (error) {
|
|
console.error("Failed to resolve params:", error);
|
|
}
|
|
};
|
|
resolveParams();
|
|
}, [props?.params]);
|
|
|
|
return (
|
|
<DashboardLayout>
|
|
{id ? <WebsiteSettings websiteId={id} /> : <div>Loading...</div>}
|
|
</DashboardLayout>
|
|
);
|
|
}
|