Back to skills
SKILL.md
React Typescript
ASecurityUse a generic component: ```tsx interface ListProps<T> { items: T[]; renderItem: (item: T) => ReactNode; keyExtractor: (item: T) => string; } function List<T,>(props: ListProps<T>): JSX.Element { /* render props.items */ return <>{props.items.map(props.renderItem)}</>; } ``` The generic `<T,>` comma avoids TSX parser ambiguity and preserves the item type.
- 549 stars
- 0 votes
- 0 copies
- 1 view
- Added September 5, 2026
Security analysis
100/100Pro scans all 11 files and shows the line behind each finding
npx -y skills add HoangNguyen0403/agent-skills-standard --skill react-typescript --agent claude-codeAre you the author of React Typescript?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/hoangnguyen0403-react-typescript-5e6b6085)Use a generic component:
```tsx
interface ListProps<T> { items: T[]; renderItem: (item: T) => ReactNode; keyExtractor: (item: T) => string; }
function List<T,>(props: ListProps<T>): JSX.Element { /* render props.items */ return <>{props.items.map(props.renderItem)}</>; }
```
The generic `<T,>` comma avoids TSX parser ambiguity and preserves the item type.
Files in this skill
- eval-1.baseline.md
- eval-1.with-skill.md
- eval-2.baseline.md
- eval-2.with-skill.md
- eval-3.baseline.md
- eval-3.with-skill.md
- trigger-1.md
- trigger-2.md
- trigger-3.md
- trigger-4.md
Attribution
Comments
Loading comments…