We get many situations at work where junior developers want to introduce frameworks to every project and there are plenty of situations where that may not be the best option for different reasons. Nonetheless it is hard to convince anyone that is not a seasoned developer that introducing a framework may not be the best option for a project, because these days they’re everywhere and all the junior devs are using them.
From a personal standpoint I don’t like frameworks, I like to code in raw JavaScript or PHP or start my styling from scratch… but I do undestand other people who feel more comfortable using frameworks, however how to make non technical people understand the cons of using them is something at which I have failed in the past and ended up frustrated and feeling misunderstood.
So in this post I aim to gather some knowledge with a little bit of your help on the pros and cons of using frameworks generally and specifically. Now because I’m not experienced in many of these frameworks some of the things I list might be wrong so please correct me if so and add to it if I missed something. I will be updating this post with any good additions or corrections you can come up with and any other thing I might have missed.
Many thanks for your collaboration.
General
- Pros :
1. Junior devs can get up to speed fast
2. Online documentation and community
- Cons :
1. Licensing
2. Technical debt and more dependency
3. Short life span or incompatible upgrades
Bootstrap
- Pros:
1. Saves time styling
2. Handy grid system
- Cons:
1. Bad for custom designs that do not look like Bootstrap as it will introduce a lot of clutter
jQuery
- Pros :
1. Event standarisation
2. Handy dom node selectors (no longer relevant since querySelector and querySelectorAll)
- Cons :
1. Too many redundant methods
2. Developers learn the language abstraction instead of the language itself
Require.js
- Pros :
1. easily require dependencies
- Cons :
1. easily solved by propper app initialization or a php script
2. too much redundancy in the code
React.js
- Pros:
1. Component architecture
2. Fast rendering
3. Works well with other libraries/frameworks
- Cons:
1. Just the view layer
2. Ties code to html structures and promotes technical debt
3. Hard to deal with forms because of non-mutable input states
4. Dodgy terms and conditions (https://medium.com/bits-and-pixels/a-compelling-reason-not-to-use-reactjs-beac24402f7b#.yple4sfpi)
ES6 (I know this is not a framework but seems to be a new buzzword so decided to add it)
- Pros:
1. Introduces a lot of new cool features
- Cons:
1. Introduces too much dependency at the moment (Babel)
2. ES5 is very powerful but misunderstood
3. ES6 obscures the real prototypal nature of JavaScript