Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Article: 10 Simple Rules I would Tell Myself 15 years Ago #106

Open
igr opened this issue Apr 11, 2018 · 0 comments
Open

Article: 10 Simple Rules I would Tell Myself 15 years Ago #106

igr opened this issue Apr 11, 2018 · 0 comments
Assignees
Labels

Comments

@igr
Copy link
Member

igr commented Apr 11, 2018

Here are 0x0A advices. They seems simple but can be very powerful in the right hands. Don't follow them, but challenge them instead; make your own list.

  • Refactor a lot. Don't refrain just because the current code works. Development is not about writing the code, it's about refactoring so it becomes more understandable to the human readers, not computers.
  • Naming is a king. Invest time in good names. Like, reallyGoodNames().
  • Libraries over frameworks. Each framework captures you within its own boundaries. That's neither good or bad, it's just how it is. However, most of the time the framework can be replaced with simple(r) libraries that conceptually do the same, and leave more freedom for leaner architecture.
  • Composition over Inheritance. Inheritance is one very strong connection. While some languages (like Java) almost forces usage of inheritance, use it occasionally.
  • Short, but many. Write shorter code, but allow many classes and methods to exist. It's better to have more types, then the single god-class.
  • Document decisions. Write down why some architecture, tool or pattern is not been used or chosen. Write down also why some solution is chosen.
  • Benchmarks as a proof of an optimization. Do not optimize for speed unless you have a benchmark that defines a bottleneck.
  • Establish boundaries. Build modules with single purpose. Define communication channels: API, interfaces. Make loosely coupled components. Control the side-effect by minimizing them.
  • Developer first tooling. Optimize your environment as much as possible. Automate. Automate more. Developers should develop. Don't waste their time on trivial tasks. Infrastructure should run out of the box.
  • Generalization vs Specification - find the sweet spot between generalization and specification. Generalization is abstraction, but too much of it may introduce unwanted complexity.
@igr igr changed the title Article: Simple Rules I would Tell Myself 15 years Ago Article: 10 Simple Rules I would Tell Myself 15 years Ago Apr 11, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants