4 ms·
I see two benefits of frontend JS frameworks: 1. They are highly optimized for DOM changes. You can use plain JS or jQuery to manipulate DOM but that would get
by amerkhalid 9y ago
I see two benefits of frontend JS frameworks:
1. They are highly optimized for DOM changes. You can use plain JS or jQuery to manipulate DOM but that would get expensive.
2. They provide some semblance Object Oriented code organization to frontend.
For a simple app, these benefits probably are not worth it but for a complex app, these benefits outweigh the cost of these frameworks.
- ccachor 9y agoI'd also add, moving to components doesn't rely on DOM structure either (ex. $(this).parent().parent().find(:el)...)
- rhapsodic 9y ago> 1. They are highly optimized for DOM changes. You can use plain JS or jQuery to manipulate DOM but that would get expensive. I keep seeing this claim, or similar ones, postulated, but in my extensive experience, using plain JS or JQuery for DOM manipulation has never resulted in noticeably slow performance, even when there was a great deal of DOM manipulation going on. And if that were the case, I am quite confident in my ability to optimize my own code to make it performant.
- glassbordall 9y agoAgreed. Furthermore, OO style programming is simple enough with plain JS.