Swift Style Guides (a brief look)
5 (1)

Last Updated on November 14, 2021 by deya

You most probably was working on an open source project, and must have noticed projects are usually organized and consistent 🧐, this is due to following a code style, and you must have noticed that some projects are messy, ugly and inconsistent 🤮.

There are different Swift Code Styles, one by Apple, Google, Ray Wenderlich, Linkedin and AirBNB, and others, preferring a code style over another is subjective, I recommend inspecting different styles and adopt one according to the project needs.

Developers spend time reading code, more than writing new code 😌, this alone justifies having a consistent clean coding style, this is an investment you do for yourself as a developer, and for your colleagues 😇, regular indentation, proper spelling, .. etc does not make your task take longer, in the contrary, it saves you big load of time in the future, and improves readability and maintainability.

There is an official API Design guidelines, it covers naming conventions, but is not comprehensive enough.

Another guideline can be found here, by Nikita Lazarev-Zubov, it looks like she has preservations on some guidelines too, I highly recommend going through these guidelines and inspecting yourself.


Click to rate this post!
[Total: 1 Average: 5]

Leave a Reply

Your email address will not be published. Required fields are marked *