How yacho-glitch/github-user-finder works
GitHub User Finder lets a user search for a GitHub username, then displays profile details and up to ten recently updated public repositories. The app debounces input, builds GitHub API URLs, fetches user and repository data independently, and renders loading or error feedback alongside the results. The graph follows the visible component calls and fetch behavior; the API service defines endpoint URLs, while the browser fetches them. Styling and type definitions support the interface and data but are not separate workflow stages.
Main entry points: App.tsx App coordinator · SearchBar.tsx Debounced search · RepoList.tsx Repository list · github.ts GitHub data types
Components 14
Search and results
- Debounced search
src/components/SearchBar.tsx - User profile
src/components/UserProfile.tsx - Repository list
src/components/RepoList.tsx - Repository card
src/components/RepoCard.tsx - Loading feedback
src/components/LoadingSpinner.tsx - Error feedback
src/components/ErrorMessage.tsx
Application runtime
- React entry
src/main.tsx - App coordinator
src/App.tsx - Debounce hook
src/hooks/useDebounce.ts - Fetch hook
src/hooks/useFetch.ts - GitHub data types
src/types/github.ts
GitHub API
- GitHub URLs
src/services/githubApi.ts - GitHub API
Other components
- User
Connections 16
- User → React entry: opens app
- React entry → App coordinator: renders
src/main.tsx - App coordinator → Debounced search: renders
src/App.tsx - Debounced search → Debounce hook: debounces input
src/components/SearchBar.tsx - Debounced search → App coordinator: submits name
src/App.tsx - App coordinator → GitHub URLs: builds endpoints
src/App.tsx - App coordinator → Fetch hook: requests data
src/App.tsx - Fetch hook → GitHub API: fetches JSON
src/hooks/useFetch.ts - App coordinator → User profile: renders user
src/App.tsx - App coordinator → Repository list: renders repositories
src/App.tsx - Repository list → Repository card: renders each
src/components/RepoList.tsx - App coordinator → Loading feedback: renders loading
src/App.tsx - App coordinator → Error feedback: renders errors
src/App.tsx - User profile → GitHub data types: uses user shape
src/components/UserProfile.tsx - Repository list → GitHub data types: uses repo shape
src/components/RepoList.tsx - Repository card → GitHub data types: uses repo shape
src/components/RepoCard.tsx