SkillAgentSearch skills...

Coordinator

A drop-in, ready to use, collection of Coordinator protocols

Install / Use

/learn @giulio92/Coordinator
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

<p align="center"> <img src="https://github.com/giulio92/Coordinator/blob/master/GitHub%20Page/logo.png" width="500"> </p>
<p align="center"> <a href=""><img src="https://img.shields.io/badge/language-Swift%204.2-orange.svg"></a> <a href=""><img src="https://img.shields.io/badge/platform-iOS-lightgrey.svg"></a> <a href=""><img src="https://travis-ci.org/giulio92/Coordinator.svg?branch=master"></a> <a href="https://codebeat.co/projects/github-com-giulio92-coordinator-master"><img src="https://codebeat.co/badges/9a6dfd01-5249-476c-99b6-4f420cb9bbbe"></a> <a href="https://github.com/giulio92/Coordinator/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-green.svg"></a> </p>

Concepts

A Coordinator is an object that manages iOS applications navigation flow while keeping UIViewControllers separate and independent.

By itself a Coordinator can only hold references to others Coordinators and to his parent coordinator (if available), to gain navigation flow management it must be paired with a UINavigationController or UITabBarController.

Choose one of the two protocols based on your navigation flow needs:

  • NavCoordinator
    Holding a UINavigationController

  • TabCoordinator
    Holding a UITabBarController

What a Coordinator should do

  • Push a UIViewController/UINavigationController/UTabBarController of another Coordinator
  • Create Couples object
  • Present Coordinators
  • Be invisible to UIViewControllers and only known by ViewModels
  • Hold Dependencies in case of Dependency Injection

What a Coordinator should not do

  • Perform anything other than navigation (i.e. network calls)

How to use Xcode Templates

  1. Close Xcode
  2. If not already present, create a folder named Source in the following path:
    ~/Library/Developer/Xcode/Templates/File Templates/
    
  3. Move the .xctemplates of choice in:
    ~/Library/Developer/Xcode/Templates/File Templates/Source/
    
  4. Open Xcode and try to create a new file with:
    Xcode > File > New > File...
    

Example project requirements

  • Xcode 10.0+
  • Swift 4.2+
  • iOS 8.0+

Image source requirements

  • Sketch 53+

Credits

View on GitHub
GitHub Stars25
CategoryDevelopment
Updated6y ago
Forks0

Languages

Swift

Security Score

80/100

Audited on Nov 29, 2019

No findings