Skip to content

Swift Style Guides

OrlaM edited this page Apr 10, 2023 · 8 revisions

This page is a work in progress. Many of the style rules we follow are covered by Swiftlint and we are working on adding more.

Some rules we've worked out we all like:

  • Selectors: #selector(ClassName.methodName) is clearer than #selector(methodName).
  • Type inference: .white is better than UIColor.white.
  • Only use self if required.
Clone this wiki locally