startups and code

Choosing Frameworks

← Back to home

Choosing frameworks can be quite challenging.  There are a lot of frameworks out there, ExtJS, JQuery, .Net, Rails, etc...  I have used a lot of them.  I wouldn't say I am an expert at any of them, but I have learned how to learn a new framework for me.

Now, this article isn't about learning a new framework.  We all learn differently, if you think you know how to learn something new, try teaching it to someone else.  They usually will have a different way to learn the same thing.  If you really want to know something, teach it.  Ok, tangent over for now...

Choosing a framework can be quite a daunting task.  Should I use ExtJS or KendoUI?  Should I follow an MVC framework or an MVVM?  Should I use WebApi or WCF?  Ok, there are several questions that I like to ask before I add a new framework permanently to my codebase.   Note that I said "permanently".  I add a bunch of frameworks to my codebase to see what they can do... but I remove them before I finish the project.

So let's get to it... here are the questions I ask:

Why am I even considering this framework?

Usually, this question is answered pretty quickly:  I'm lazy and don't want to reinvent the wheel.  I want to make a grid, create easy data bindings, etc... Now the answer to this question is critical to the remaining questions.  If you are considering this framework because you thought it was cool from a friend of yours, you can stop now.  You don't need it yet.

How supported is this framework?

If this is some framework created by some kid last weekend, you probably don't want to use it.  If it has a supported community, a version that is past 0.01 Alpha, a list of known issues, a way to request features, etc... it is probably more stable and ready for live development.  Node.js still hasn't released a 1.0 version, but it is pretty well supported.  Had to call that out before people start slamming me for REQUIRING a 1.0 version.  None of these are requirements, just suggestions, so calm down. :-p

How easy is it for me to use?

This is a very subjective question and it is by design.  If I can use it really easy, then great.  If a person with 3 PHds in Math, Computer Science, and Physics can use it easily, then good for them.  It is about how easy it is for ME.  Why?  Because I'm the one using it!  Do I want to spend the next 3 months learning a new framework that makes my project 3 months over budget, over time?  Of course not.

How does it incorporate with what I already have written?

Do I have to scrap everything I have done so far to use this new framework?  If so, is it worth it?  It may be, but usually that answer is no.  Sometimes, you won't know the answer to this until you have already tried it (the same is true for the previous question too).

How much time is this framework going to save me?

If you don't know, then you may not need this.  If I can give a quantitative number, then it is easy to explain to management why we need this framework.  It all comes down to cost/time.

These are pretty high-level questions, but I think that if you can't answer these, you will avoid using unneeded frameworks.  Bloatware was such a buzzword in the late 90's... but because of increased bandwidth, memory, storage, we tend to throw a bunch of stuff in a project that we don't need.  Why not write clean, well-designed code?  Because it doesn't matter with the memory we have?  WRONG!  Imagine how much better it will be when it is simple, concise, and only uses what it needs... Custom jQuery builds, Custom bootstrap builds... you don't need every jquery UI, Knockout, Backbone, ExtJS for one page, KendoUI for another, Angular for another... Choose wisely... Choose with intention.

Clean code is never over-engineered

Clean code is always something you want to share

Clean code is simple, elegant, and efficient.

Write clean code, and share your experience.

Thanks for stopping by.