import { Atom, useAtom } from "jotai"; export interface IPerson { name: string; } export interface Props { personAtom: Atom; } export default function Person({ personAtom }: Props) { const [person, _] = useAtom(personAtom); return {person.name}; }