One easy trick to ensure your iOS developers are maintaining best practices and keeping your codebase readable for years to come

You’re an entrepreneur. You’re building your Minimum Viable Product (MVP). You’re probably bootstrapping it or doing it on the cheap so you can show the MVP to some investors to obtain some much needed financial solvency to prove out your concept. This means you’re probably going to hire multiple developers over the lifetime of your product, and at some point, one of your new hires will look at your existing product and tell you that it was “written poorly” or “needs to be rewritten from scratch. If you’re a first-time tech-entrpreneur, this will be a rude awakening for you. If you’re seasoned, you probably know the drill.

What if I told you there exists a solution out there that will guarantee that your code, at least the way it’s formatted and structured, is following best practices? Now, what if I told you that it’s free? You might think that I’m a snake-oil salesman, but I assure you that I’m not. What I’m referring to is known as Code Linting, and what a Code Linter does is check to make sure the codebase is following community-established best practices, defined by a style-guide, for writing and formatting your code.

In the iOS community, specifically the Swift Programing Language community, the best practices are defined in two specific style-guides:

These style guides are used to create the rules that power the linter. In the Swift community, we use SwiftLint, which is a free, open-source tool that is maintained by the very best that the Swift community has to offer.

The earlier you have your developers set a linter up in your project, the more readable your codebase will be, and the sooner your app will be following best practices, and potentially less prone to bugs. However, this doesn’t mean your app will be bug-free, or your future engineering hires wont want to rewrite your app, but it may lessen the probability of either happening early on in your venture.

Open Source Software: What is it? Why should you use it in your iOS app?

What if I told you that there are software engineers that spend much of their free time writing and maintaining software that they give away for free? You probably wouldn’t believe me, or you might even call me crazy, because you’ve most likely had a hard time hiring an engineer for your company for cold hard cash. Well, it’s true! These people, myself included, love solving problems so much that we spend our free time doing just that, and then to top it off, we give away the fruits of our labor to the community at no cost.

You might be wondering why we people in a highly-sought-after profession would participate in this endeavor? The answer is simple — we like solving problems, abstracting the solutions we discover, and sharing it with the community, so other developers won’t have to deal with these headaches. (Side-note: we get street-cred in our respective engineering community for solving the problem). The best part is that you, the entrepreneur with that great product idea, get to piggy-back on our solutions (for free!), which enables you and your engineers to build your app faster.

This endeavor we participate in is known as the Open Source Movement, and the creations that are put out into the world are known as Open Source Software. This software powers the web. Not only that, popular open source software projects tend to be of higher quality than most other software, as this type of software, by its very nature, is inspected, edited, augmented, tested, and vetted by the community that uses it.

This begs the question, why should you use it? Simple — many open source projects, at least the ones that are maintained and vetted by the community, tend to solve common engineering problems. Why reinvent the wheel? This allows your engineers to concentrate on building the specific, challenging, and proprietary solutions required for your product to be successful. However, there are some exceptions to the rule. Both Realm and Artsy, two companies composed of developers that are considered luminaries in the iOS community, build their main products out in the open. They can do that because their product isn’t their main income generator; it’s the platform that these software tools leverage that generate the income.

In a future post on this blog, we’ll cover the specifics of where you can find Open Source solutions specific to the iOS community.