파일 위치 /app/(dashboard)/[storeId]/(routes)/settings/page.tsx
실제 예시 url
하는 것
params를 받아온다. (서버 컴포넌트도 {params})로 url의 params를 받을 수 있음.interface SettingPageProps {
params: {
storeId: string;
};
}
export default async function SettingsPage({ params }: SettingPageProps) {
return <div>페이지 뭐시기</div>
}
const store = await prismadb.store.findFirst({
where: {
id: params.storeId,
userId,
},
});
SettingForm 이라는 컴포넌트에 store을 넘겨준다.UI

하는일
api-routes 사용api-routes 사용
react-hook-form + zod로 폼 관리shadcn의 Alert 컴포넌트 사용