soma.js version 2 has finally been released!

Even though it shares the same goals as the previous version, the version 2 is completely different.

What is soma.js?

To set up a landscape, soma.js is a framework created to build scalable and maintainable javascript applications.

So yes, that’s another javascript framework. soma.js can be used as an MVC framework but its structure is so flexible that it can be used differently to fit your needs.

Why soma.js?

The following might not ring a bell to everyone, but the only thing developers should care about is writing code that is maintainable. This is sort of an ultimate goal to reach. And sometimes, it can be really hard, even for seasoned teams of developers.

Why should you bother think about that? Well, because a maintainable code will require less work and allow your application to grow. It is that simple.

It will also make you much happier, trust me. Have you never a reach a point looking at your code: “It is really becoming messy now, this will be a nightmare…”. So you know what I’m talking about?

Let me tell you something. Real large javascript apps, that are maintainable, don’t exist. Yes that’s right, they just don’t. Instead, you can find large scale javascript apps that are composed of a lot of pieces put together. This is more like it. These pieces can be called modules or other names.

In all successful and maintainable structures, these smaller pieces probably have a common point: they have very small number of dependencies. In other words, these smaller pieces can work on their own and don’t know about the application itself. They can be swapped, interfaced. They are meant to do a single job, nothing more, and have no idea what other elements will do with it. They are put together, moved, refactored, enhanced, and so on.

This is the success key of building large javascript applications, or in fact, any application.

This is what soma.js is about. You will write pure plain javascript as you are used to, and the framework will provide tool to help you reduce dependencies and make your code more maintainable and testable.

What is different in soma.js?

One day, and this wasn’t using javascript, I’ve started tackle “frameworks”. The idea was simple, they help build something. These interests in frameworks quickly drove me in blog posts showing obsessions about how code should be written, best practices basically.

They all had the same goal: make your developer life easier.

People are talking about their framework of choice, what is good and what is not. Some famous developers offering solutions to solve problems in more effective ways. And so on.

In different languages, I saw something happen. All these highly-coupled code problems, dependencies, non-maintainable code issues, and framework fights, got a solution that has been a revelation for a lot of developers: dependency injection.

Of course, I’m not saying that dependency injection is a solution for everything and should be used everywhere. But where complexity lies, I’m a strong believer in dependency injection. I also think that it has been a turn in a lot of developers’ carrier. It is helping, it is pretty, it is simple. You can find literally thousands of blog posts talking about its benefits, in various languages.

That is what soma.js version 2 brings: dependency injection.

How does it look?

I’ve spent a lot of time explaining the what, why and how. A site is available with tons of examples, guidelines to follow, what is dependency injection, and so on.

Click here to find out more.

Hope that will help some of you having a better time with your own code!

Romu

Share and Enjoy!