

Opinionated Rundown of JS Frameworks for Single Page Apps - HenrikJoreteg
http://blog.andyet.com/2014/08/13/opinionated-rundown-of-js-frameworks

======
t0nyh0
Despite the potential developer productivity costs associated with custom
frameworks, I've decided not to use some of the bigger frameworks for the
following reasons:

\- Performance is a feature. I like less magic, more clarity on how data flows
through my system. $digest cycles, ng-repeat will keep me up at night. I sleep
better when I know what code is doing exactly what. \- Hiring becomes easier,
i.e. do not have to screen for certain framework experience. Know JS? Good,
that's all you need!

Of course, writing your own custom application framework is no walk in the
park, but like the article said, you'll have ultimate flexibility. In my
experience, writing your own custom app framework, you have to ensure:

\- Proper dependency management, use AMD or CommonJS. The alternative:
Spaghetti jquery code.

\- Enforcing class responsiblities, e.g. ViewModels are for data
transformation and validation only. Views are for DOM management. HTML is for
layout only. CSS for styles.

\- Proper risk/reward evaluation of third party libraries. Usually, the leaner
the library the better imo.

~~~
WettowelReactor
_Hiring becomes easier, i.e. do not have to screen for certain framework
experience. Know JS? Good, that 's all you need!_

How is training someone on your custom framework any less arduous than
training them on an existing framework?

~~~
t0nyh0
It is true that your own custom framework will need to be taught as well, but
the difference between a custom framework and using a pre-existing mammoth one
is that of clarity.

I will have a better idea of how data flows through my system so that if the
new developer creates a bug, I have a better idea of where the problem may be
and be able to isolate it better. Whereas, if you use a heavy pre-existing
framework, you run the risk of not knowing. The subtle bugs can be pretty
dangerous.

In the case of hiring, if I have a good JS developer, I can show him easily
how data flows through the system because it is more clear (if architected
properly). If I used a heavy framework, I may have to expect him to know the
subtleties of these external frameworks, and may even have to act in the role
of an "architect" to dissect it.

It's a balance to achieve between speed and productivity. My personal style is
to err on clarity and not magic.

