Project introduction

Let's build News application in Swift.

It’s time to make our first application. In the first project we did a little preparation, but now it’s time for the real coding to take place. In this project we will be creating an iOS application from scratch using Swift and Test Driven Development.

This application will be similar to the Apple News app, but it will be much more simplified.

The idea is to present news from different sources, all in one place, so that the users can read the latest news using just one app. News will be divided into categories, so you can easily pick what interests you the most. We will use our custom API to serve all of the news and articles. For now it will contain only static data, but in future projects we will create real API in Server Side Swift.

User interface

The application will have a classic navigation with navigation bar on the top and tab bar on the bottom. However, the tab bar will be a custom element built from scratch. There will be five tab bar elements, the middle one will be slightly bigger than others. Icons will change colors while being selected, middle element will also have a red background.

Navigation bars will mostly be system components, they will be only customized on some screens and hidden in one of them.

The whole application will be presented in portrait mode. Most of the time we will use table views to present news list.

You can get design files from here. To open them download and install Sketch app. More about Sketch and how to work with it I will cover inside next article. Don’t worry if you haven’t used it yet.

The design requires new default Apple font: San Francisco. To download this font just visit Apple website, and choose "For iOS, macOS, and tvOS".

Modules

Let’s briefly go through each of the modules.

Latest news

Latest news

This module will show a list of the latest news. The list will be divided into three sections:

  • All - show all off the available news
  • Today - show only today’s news
  • Trending - show most popular news

Each news item is assigned to one category.

Lists are ordered by descending date.

This is the default module that is presented after the application has been launched.

Categories

Latest news

This module presents the news grouped in categories. Each category has its own background image and name.

Live feed

Latest news

This module presents live news. The news that are updated constantly, as soon as the new information is available it’s shown on screen. These are just short news, usually under 300 characters.

Featured

Latest news

This module presents special stories. Those stories are longer essays with photos. Each special story has a full screen cover photo as a start page.

Favorites

Latest news

Module Favorites presents all of the news that have been marked as favorite by the user. All favorite news are displayed as a list and work similar to the latest news module.

In this brief overview we have covered the basic functionality of the application. When we will start coding I will provide more details about each of the module.

But before we will code anything let’s talk about necessary tools. In the next step we will get to know the list of required applications that we will be using during the development.