Skip to content

A simple news app allows searhcing for news given a search term.

Notifications You must be signed in to change notification settings

AbdAllahAbdElFattah13/simple-news-app

Repository files navigation

simple-news-app

A simple news app allows searhcing for news given a search term.

Demo

Demo video

Setup

To be able to build this app locally, you need to have API key from newsapi.org. To include the API key in the project follow the steps:

  1. Go to newsapi.org.
  2. Click Get API Key
  3. Register a free/developer account to obtain the API key.
  4. Copy the provided API key.
  5. In app root directly, open local.properties file. If it's not there, create one.
  6. Paste the provided API key into the file in the following form: newsApiKey="xxxxxxxxxxxxxx"
  7. Now you should be able to build and run the app normally.

App Architecture overview

App follows Google's recommended app architecture, which consists mainly of the following layers:

  • UI. Single Activity with multiple Fragments
  • Presentation. ViewModel/LiveData
  • Repository to abstruct data sources.
  • Remote. Unofficial Java News client

Paging 3 in conjunction with Rxjava 2.x was used to handle the news pagination.

Android Navigation Component was used to handle navigation between different screens and pass data between screens.

Dependencies are bing injected manually which works fine for now.

JUint 4, mockito-kotlin along side some android core testing libraries were used for unit tests.

Communication

  • To contribute: check the issues for the issue or the feature request first, if it's not there please create one. Once discussed feel free to fork and create a PR for review.
  • For questions: Open an issue and add the question label to it.

About

A simple news app allows searhcing for news given a search term.

Topics

Resources

Stars

Watchers

Forks

Languages