Install any skill in seconds. Free to start, no credit card required.
Get Started Free →loulanyue/frontend-patterns
Frontend development patterns for React, Next.js, state management, performance optimization, and UI best practices.
Passed 14 of 22 test cases with the skill, and 10 of 22 without it.
and 5 more in the full report
4 fixed10 passed either way8 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 4 test cases the skill fixed. Same model, same prompt, with and without the skill.
We have a dataset of over 5,000 items that needs to be displayed in a web app, but rendering all DOM nodes at once causes lag. Please provide a React TypeScript code snippet demonstrating how to virtualize this long list with absolute positioning and scroll estimation.
| Checked | Without skill | With skill |
|---|---|---|
| Uses useVirtualizer from @tanstack/react-virtual to handle list virtualization | Missed | Passed |
| Sets total container height dynamically using virtualizer.getTotalSize() | Missed | Passed |
| Applies absolute positioning and translateY transforms to virtual item wrappers | Missed | Passed |
The instructions your model reads when the skill loads.
用於 React、Next.js 和高效能使用者介面的現代前端模式。
// ✅ 良好:元件組合
interface CardProps {
children: React.ReactNode
variant?: 'default' | 'outlined'
}
export function Card({ children, variant = 'default' }: CardProps) {
return <div className={`card card-${variant}`}>{children}</div>
}
export function CardHeader({ children }: { children: React.ReactNode }) {
return <div className="card-header">{children}</div>
}
export function CardBody({ children }: { children: React.ReactNode }) {
return <div className="card-body">{children}</div>
}
// 使用方式
<Card>
<CardHeader>標題</CardHeader>
<CardBody>內容</CardBody>
</Card>
interface TabsContextValue {
activeTab: string
setActiveTab: (tab: string) => void
test cases passed, vs 10 / 22 without
Published skills whose descriptions closely match this one, with their headline benchmark lift.
More skills from the same source and nearby in the registry, with their headline benchmark lift.