클라이언트컴포넌트

NextJs를 사용해서 포트폴리오 페이지를 만들던 중 lottie player를 사용하던 과정에서 오류와 마주했습니다. 오류 내용 error - useState only works in Client Components. Add the "use client" directive at the top of the file to use it. Read more: https://nextjs.org/docs/messages/react-client-hook-in-server-component at stringify () 이 오류는 SSR에 사용할 수 없는 React hook을 사용하려고 하면 발생하는 오류입니다. NextJs에서는 서버 컴포넌트와 클라이언트 컴포넌트를 구분하는데, 두 컴포넌트는 다른 환경에서 실행됩니다..