Download wp-calypso/packages/components/src/card/compact.tsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 393 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/packages/components/src/card/compact.tsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/packages/components/src/card/compact.tsx
-
curl -L -o compact.tsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/packages/components/src/card/compact.tsx
393 Bytes
| import { forwardRef } from 'react'; | |
| import Card from '.'; | |
| import type { Props, TagName } from '.'; | |
| import type { Ref } from 'react'; | |
| const CompactCard = forwardRef( | |
| < T extends TagName >( props: Omit< Props< T >, 'compact' >, ref: Ref< unknown > ) => ( | |
| <Card { ...( props as Props< T > ) } compact ref={ ref } /> | |
| ) | |
| ); | |
| CompactCard.displayName = 'CompactCard'; | |
| export default CompactCard; | |