From 10b5de7a2114e48d79c551394d8db492a9eb595a Mon Sep 17 00:00:00 2001 From: Hannah_Bagga Date: Thu, 18 Jun 2026 15:29:55 +0200 Subject: [PATCH] Fix ESLint import paths and Next.js 15 params type for leads page --- eslint.config.mjs | 8 ++++---- src/app/(dashboard)/leads/[id]/page.tsx | 6 ++++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/eslint.config.mjs b/eslint.config.mjs index 05e726d..e1d1c19 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -1,10 +1,10 @@ import { defineConfig, globalIgnores } from "eslint/config"; -import nextVitals from "eslint-config-next/core-web-vitals"; -import nextTs from "eslint-config-next/typescript"; +import nextVitals from "eslint-config-next/core-web-vitals.js"; +import nextTs from "eslint-config-next/typescript.js"; const eslintConfig = defineConfig([ - ...nextVitals, - ...nextTs, + nextVitals, + nextTs, // Override default ignores of eslint-config-next. globalIgnores([ // Default ignores of eslint-config-next: diff --git a/src/app/(dashboard)/leads/[id]/page.tsx b/src/app/(dashboard)/leads/[id]/page.tsx index 7530b5e..c28094d 100644 --- a/src/app/(dashboard)/leads/[id]/page.tsx +++ b/src/app/(dashboard)/leads/[id]/page.tsx @@ -17,10 +17,12 @@ import { } from "@/components/ui/select" import { getLeadById } from "@/data/leads" import { getNotesByLeadId } from "@/data/notes" +import { use } from "react" import { ArrowLeft, Edit, ExternalLink } from "lucide-react" -export default function LeadDetailsPage({ params }: { params: { id: string } }) { - const lead = getLeadById(params.id) +export default function LeadDetailsPage({ params }: { params: Promise<{ id: string }> }) { + const { id } = use(params) + const lead = getLeadById(id) const leadNotes = lead ? getNotesByLeadId(lead.id) : [] if (!lead) {