Skip to content

A Flutter-based News App that displays the latest news articles across various categories. The app features a splash screen, search functionality, and categorized news lists.

License

Notifications You must be signed in to change notification settings

mohamedmagdy2301/news_app

Repository files navigation


Typing SVG

Flutter Version License: MIT

A Flutter-based News App that displays the latest news articles across various categories. The app features a splash screen, search functionality, and categorized news lists.

Features

  • Splash Screen: Displays an animated splash screen before navigating to the homepage.
  • News Categories: View news across different categories like Business, Entertainment, Health, Science, Sports, and Technology.
  • Search News: Search functionality to quickly find news articles.
  • Latest News: Displays the most recent articles on the homepage.
  • News Details: View detailed news articles with images and content.

Screens

  • Splash Screen: An animated splash screen with the app logo and transition to the home page.
  • Home Page: Displays categorized news using a TabBarView and a list of the latest news.
  • News Details: A detailed view for each news article, including images, author information, and published date.

Technologies & Packages

  • Flutter: Dart-based framework for cross-platform mobile development.
  • SplashScreenView: A library for adding a splash screen with animations.
  • CachedNetworkImage: For displaying images with caching functionality.
  • Shimmer: Used for displaying placeholder animations while data is being loaded.

Folder Structure

lib/
├── main.dart                         # Main entry point of the app
├── screen/
│   └── home_page.dart                # Home page with TabBar and latest news list
├── widget/
│   ├── all_news/
│   │   ├── news_list.dart            # Widget to display list of news articles
│   │   └── tab_bar_build.dart        # Custom TabBar widget for news categories
│   ├── lastest_news/
│   │   └── horizontal_list_recent_news.dart  # Widget for displaying latest news in a horizontal list
│   └── search/
│       └── search_news_build.dart    # Widget for search functionality
└── api/
    └── get_news_service_api.dart     # Service class for fetching news from the API

Getting Started

Prerequisites

Installation

  1. Clone the Repository

    git clone https://github.com/your-username/news-app.git
    cd news-app
    
  2. Install Dependencies

    flutter pub get
    
  3. Run the App

    flutter run
    

API Integration

To fetch news data, the GetAllNewsService in get_news_service_api.dart should be configured with a news API endpoint. You can use any public API like NewsAPI. Make sure to add your API key to the request function.

Usage

  • Upon launching the app, you will see the splash screen with the app logo.
  • After the splash screen, the home page will show the latest news and a tab bar with different categories.
  • Click on any category to view the relevant news.
  • Use the search bar to find specific news articles.
  • Click on any article to read more details.

Screenshots

Splash Screen Home Page News Details
Splash Screen Home Page News Details

Contributing

Contributions are highly encouraged! If you would like to contribute to News App, please follow these steps:

  1. Fork the Repository.
  2. Create a New Branch:
    git checkout -b feature/YourFeature
  3. Commit Your Changes:
    git commit -m "Add your message"
  4. Push to the Branch:
    git push origin feature/YourFeature
  5. Open a Pull Request.

Congratulations

You’ve successfully integrated News App into your Flutter app! For more advanced features and customization options.

If you found this guide helpful, don’t forget to ⭐ star this repository on GitHub to show your support!

Thank you for reading!

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contact

For any questions or inquiries, feel free to reach out:

About

A Flutter-based News App that displays the latest news articles across various categories. The app features a splash screen, search functionality, and categorized news lists.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published