Skip to content

Code guidelines

Dana Lewis edited this page Apr 1, 2020 · 4 revisions
  • Use Swift.
  • Keep it simple!
  • Keep functions and classes reasonably short.
  • Minimize side effects.
  • Avoid force unwrap.
  • Minimize usage of implicitly unwrapped optionals. Only IBOutlet and similar.
  • Prefer composition over inheritance.
  • Prefer immutability.
  • Prefer explicit type declarations for instance variables.
  • Use readable names.
  • If something is difficult to understand, add some documentation.
  • Preferred to avoid storyboards (open to discussion)
  • Prefer XIBs. For now use SwiftUI only for simple UIs or if feeling confident that there will be no bugs.

Getting started?

  • Use (and target) the develop branch
  • Make sure you’re opening the .xcworkspace not the .xcproj file in xcode
  • If you get framework not found Pods_CoEpi, don't forget to pod install
Clone this wiki locally