Swift Enlightenment

I started this this blog to better expand my knowledge of Swift and hope to help others do the same. I have already known Swift but will start from the basics. This was inspired by a couple other blogs and repos, just decided to make my own, and open source

30 Projects so far..

Project 1 - Tap Counter

A simple tap counter, where you tap on the button and it increments the number. Pressing reset sets the number back to zero.


  • Build an Interface with Labels and Buttons

  • Using functions with buttons

  • String Interpolation

Project 2 - Show Alert

Pressing a button to makes an alert popup.


  • Build an Interface with Labels and Buttons

  • Using functions with buttons

  • UIAlertController

Project 3 - Tip Calculator

Simple Tip Calculator


  • CocoaPods

  • mySliderValueChanged

  • UIControlEvents.EditingChanged

Project 4 - Stopwatch

A simple stopwatch that can start counting, pause, and reset.


  • NSTimer

  • scheduledTimerWithTimeInterval

  • Timer invalidate

Project 5 - Font Changer

Pressing a button changes the custom font to another custom font.


  • UIFont

  • Custom Fonts

Project 6 - TableView

Creating a basic TableView


  • UITableViewDelegate

  • UITableViewDataSource

Project 7 - CollectionView

Creating a basic CollectionView


  • UICollectionViewDataSource

  • UICollectionViewDelegate

  • dequeueReusableCellWithReuseIdentifier

Project 8 - Play Local Video

Play video that is saved locally in the app.


  • NSBundle.mainBundle

  • AVPlayer

Project 9 - Play YouTube Video

Play video that is on Youtube.


  • YoutubeSourceParserKit

  • MediaPlayer

Project 10 - Get Time

Gets the current date and time to the second. Pressing the update button updates the date / time.


  • NSDateFormatter

Project 11 - Passing Data

Gets the current date and time to the second. Pressing the update button updates the date / time.


  • destinationViewController

Project 12 - Slide To Dismiss

Using UISwipeGestureRecognizer we can slide down to dismiss the keyboard.


  • UISwipeGestureRecognizer

  • resignFirstResponder

Project 13 - Image Picker

Pressing a button will bring up the image picker. The user then chooses the image and it is shown in an image view.


  • UIImagePickerController

  • UINavigationControllerDelegate

  • UIImagePickerControllerDelegate

  • UIImagePickerControllerSourceType

Project 14 - Pull to Refresh

Sliding down on a table view refreshes the list.


  • UIRefreshControl

Project 15 - Delete Rearrange

Deleting and rearranging cells in a table view.


  • UITableView

  • canMoveRowAtIndexPath

  • moveRowAtIndexPath

Project 16 - Add To List

Adding an item to a TableView


  • Append to array

  • reloadData

Project 17 - Custom TableView

Creating and populating custom cells in TableViews


  • dequeueReusableCellWithIdentifier

  • UITableViewCell class

  • configureCell method

Project 18 - Custom CollectionView

Creating and populating custom cells in CollectionView


  • sizeForItemAtIndexPath

  • UICollectionViewCell class

  • configureCell method

Project 19 - GetLocation

Creating and populating custom cells in CollectionView


  • CLLocationManager

  • MapKit

  • didUpdateLocations method

Project 20 - ActionSheets

Pressing the share button brings up an ActionSheet where you have more buttons to choose from.


  • UIActionSheetDelegate

  • UIAlertController

  • UIAlertAction

Project 21 - BackgroundVideo

Sometimes video intros are pretty cool!


  • VideoSplashViewController.swift

  • VideoCutter.swift

  • preferredStatusBarStyle

Project 22 - ScrollView

Using a scrollview to scroll down the page to see further content.


  • UIScrollView

Project 23 - SplashScreen

Twitter like splash screen.


  • http://iosdevtips.co/post/88481653818/twitter-ios-app-bird-zoom-animation

Project 24 - Localization

Using localizable strings. When the system language is changed, the strings in the app change.


  • Localizable.strings

  • http://rshankar.com/internationalization-and-localization-of-apps-in-xcode-6-and-swift/

Project 25 - BasicAnimations

Creating basic animations for textfields, button, and a label. Textfields and buttons slide on and off and title labels alpha is set to 0.


  • animateWithDuration

Project 26 - SnapChatLikeCamera

Swiping right or left goes to different views. One of which is a camera.


  • Appending views to scroll views

  • Accessing the front camera

  • https://www.youtube.com/watch?v=994Hsi1zs6Q

Project 27 - LimitingCharacters

Limiting characters of a textfield to a set number.


  • shouldChangeCharactersInRange

  • editedTextField

Project 28 - APICall

Making and API call with Alamofire then parsing the JSON object with SwiftyJSON


  • Alamofire

  • SwiftyJSOn

Project 29 - FullScreeniAd

Needed to implement a full screen iAd in my app and thought I would post a little project here too.


  • Interstatial Ad

  • Delay of 1 second

Project 30 - SlideOutMenu

Drag across the screen to open up a menu.


  • https://www.youtube.com/watch?v=8EFfPT3UeWs

  • SWRevealViewController