How syedibad12/digitalnews works
DigitalNews is a React news-browsing app: readers choose a headline category, the app requests paginated top headlines from NewsAPI, and displays article cards with links to the original stories. The sampled source supports the route, fetch, scroll-pagination, and card-rendering flow. Other runtime styling and assets are present in the tree but are not needed to explain this workflow.
Main entry points: NewsComponent.jsx News controller · App.jsx App routes · NavBar.jsx Category links · NewsItems.jsx Article cards
Components 9
Category Navigation
- App routes
news-app/src/App.jsx - Category links
news-app/src/components/NavBar.jsx
Headline Retrieval
- News controller
news-app/src/components/NewsComponent.jsx - NewsAPI
- Article state
news-app/src/components/NewsComponent.jsx
News Presentation
- Article cards
news-app/src/components/NewsItems.jsx - Loading indicator
news-app/src/components/Spinner.jsx
Other components
- News reader
- Publisher story
Connections 9
- News reader → Category links: chooses category
- Category links → App routes: navigates route
- App routes → News controller: renders category
- News controller → NewsAPI: requests headlines
- NewsAPI → News controller: returns articles
- News controller → Article state: updates articles
- Article state → Article cards: renders entries
- News controller → Loading indicator: shows loading
- Article cards → Publisher story: opens story