Displays a line chart showing repository commit activity over the last 90 days

Features:

  • Fetches commit history using GitHub GraphQL API
  • Displays daily commit frequency as a line chart
  • Interactive tooltips showing date and commit count
  • Smooth line transitions with tension
  • Area fill for visual emphasis
  • Responsive design that maintains aspect ratio

Visual States:

  • Loading: Shows animated placeholder
  • Error: Displays appropriate error message
  • Empty: Shows message when no commit data available
  • Rate Limited: Special message for API rate limiting

Chart Configuration:

  • 90-day time window
  • Hidden axes for clean appearance
  • No data points for smoother look
  • Nearest point interaction mode
  • Custom tooltip formatting

Error Handling:

  • API rate limit detection
  • Rendering error fallback
  • Console error logging
  • Cache-first data strategy
<CommitChart owner="facebook" repoName="react" />