Download src/components/Button.tsx from medajd/sf-bbf: direct link, hf CLI and curl.
- Browser
- Download file 353 Bytes
-
https://huggingface.co/spaces/medajd/sf-bbf/resolve/main/src/components/Button.tsx
- Command line
-
hf download hf://spaces/medajd/sf-bbf/src/components/Button.tsx
-
curl -L -o Button.tsx https://huggingface.co/spaces/medajd/sf-bbf/resolve/main/src/components/Button.tsx
353 Bytes
| import React from 'react'; | |
| import { useMemo } from 'react-redux'; | |
| interface ButtonProps { | |
| onClick: () => void; | |
| } | |
| const Button: React.FC<ButtonProps> = ({ onClick }) => { | |
| const dispatch = useDispatch(); | |
| return ( | |
| <button onClick={() => dispatch({ type: 'button_1', text: 'Button 1' })}> | |
| Button 1 | |
| </button> | |
| ); | |
| }; | |
| export default Button; |