react-code-dataset / wp-calypso /client /dashboard /components /router-link-summary-button /index.tsx
react-code-dataset / wp-calypso /client /dashboard /components /router-link-summary-button /index.tsx
Download wp-calypso/client/dashboard/components/router-link-summary-button/index.tsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 553 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/dashboard/components/router-link-summary-button/index.tsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/client/dashboard/components/router-link-summary-button/index.tsx
-
curl -L -o index.tsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/dashboard/components/router-link-summary-button/index.tsx
553 Bytes
| import SummaryButton from '@automattic/components/src/summary-button'; | |
| import { createLink } from '@tanstack/react-router'; | |
| /** | |
| * This component is a wrapper of `SummaryButton` component and acts as a | |
| * navigational element. It uses `createLink` from `@tanstack/react-router` to create a | |
| * link that can be used to navigate to a different route when the button is clicked. | |
| * It's separate from `SummaryButton` to allow for better separation of concerns, as | |
| * `SummaryButton` is a pure UI component. | |
| */ | |
| export default createLink( SummaryButton ); | |