When you start your business or simply working as a tech team, you always have a goal in mind, something great to achieve. Most of the time, the projects I saw failed did so not because they were bad, but because the team responsible for it was not able to get mature enough to everything would go smooth. In this article, I’ll try to describe my path to the maturity.

Clean code

First thing first, you need to have your code clean. I personnaly always follow this rule :

I code the want I would want to read anyone’s code, and I code so that anyone would read my code

This means it does not matter how you code, what matters is that everyone on the team can read it. Once I had to work in a company which was using a paradigm in Javascript I did not like, but because everyone else was enjoying it, my place was not to say anything but follow the flow. This being said, the best way to achieve that is by defining some coding rules and sticking to it. I recommend any linter tool you prefer. Here in Umanlife, we use eslint.o

Version control

You could have a nice coding style, you’d never escape from mistakes. This best way to be extra careful is to version your code. This is not something I should try to convince you with, so go tackle it ! We use git through Github.

Test coverage

We humans do mistake, better get along with it, there is nothing you could do. It is the same with coding, you could be any sort of coding genius, you’d still do silly mistakes sometimes (or you are a robot). The best way to prevent so is to test you code in a smart way :

I know it could get frustrating, and at the beginning you’d probably spend more time implementing test than coding, but believe me, when your project will be running in production, you’ll thank the tests for not having any regression from one version to the other.

Automatic delivery

That being said, you should now have quite a nice pipepline : You code is linted and tested, and you can follow your version. But as your project get bigger, all those tasks take you forever just to get one new version in production. This is when Continuous Integration comes ! Using tools such as circleci, as we do in Umanlife, will allow you to automate most of this, leaving you with the important job. I always follow this rule :

If it takes you more than 90 seconds and you need to do it more than once, automate it !

Secure and log

The last chapter of this article will be about security : For me logs are part of a secure system, they should allow you to spot directly what went wrong and quickly react. They are essential to your project. Here in Umanlife, when use a MQTT broker on which when send all sorts of events. Those events are then computed and analysed so we can give the best experience to our consumers.

Conclusion

Of course you won’t achieve maturity just by following all those rules, but I believe those are a nice first step. I’ll try to give you the rest in a next article.