Upgrade to Pro — share decks privately, control downloads, hide ads and more …

iOS Navigation without Storyboards (iOSDevUk 2016)

AppFoundry
September 07, 2016

iOS Navigation without Storyboards (iOSDevUk 2016)

Lightning talk by Jens Goeman at iOSDevUK 2016.

AppFoundry

September 07, 2016
Tweet

More Decks by AppFoundry

Other Decks in Technology

Transcript

  1. Navigation in a world
    without Storyboards

    View Slide

  2. Jens Goeman

    Developer
    [email protected]
    @goesman_


    View Slide

  3. Storyboard

    View Slide

  4. Love
    Segue
    Flow
    Visual
    Prototype

    View Slide

  5. Hate
    Complicated
    No Reuse
    Testing
    !Merging Hell!

    View Slide

  6. Alternative

    View Slide

  7. Do it!
    in code

    View Slide

  8. Do it!
    Do it!
    Testable
    "Merging Heaven" (most of the time)
    Reuse

    View Slide

  9. Do it?
    Autolayout in code?
    No visual overview
    Testing a UIViewController
    *.xibs FTW

    View Slide

  10. How we do it

    View Slide

  11. NavigationManager
    One dependency
    Single point of contact
    Knows nothing
    Needs input

    View Slide

  12. Input
    Which navigation?
    Parameters
    Error block
    Initiator

    View Slide

  13. Navigator
    Does all the work
    Create VC
    Inject Parameters
    Present VC
    Report

    View Slide

  14. FLOW

    View Slide

  15. 1* Captain App yells his input

    View Slide

  16. 2* NavigationManager gets input

    View Slide

  17. 3* NavigationManager makes a corresponding navigator
    #

    View Slide

  18. 4* Navigator makes the new ViewController and presents it
    #

    View Slide

  19. 5* Win
    #
    $

    View Slide

  20. DRYNavigationManager

    View Slide

  21. Next up:

    Swift

    View Slide

  22. This is my back

    View Slide

  23. Jens Goeman

    Developer

    View Slide