Download next.js/examples/blog-with-comment/components/comment/index.tsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 420 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/examples/blog-with-comment/components/comment/index.tsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/examples/blog-with-comment/components/comment/index.tsx
-
curl -L -o index.tsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/examples/blog-with-comment/components/comment/index.tsx
420 Bytes
| import CommentForm from "./form"; | |
| import CommentList from "./list"; | |
| import useComments from "../../hooks/useComment"; | |
| export default function Comment() { | |
| const { text, setText, comments, onSubmit, onDelete } = useComments(); | |
| return ( | |
| <div className="mt-20"> | |
| <CommentForm onSubmit={onSubmit} text={text} setText={setText} /> | |
| <CommentList comments={comments} onDelete={onDelete} /> | |
| </div> | |
| ); | |
| } | |