Hacker News new | ask | show | jobs
by tomxor 3022 days ago
Coming from an angular world I went full spartan and just used jQuery (I tried to go native but the DOM interface is rather long winded) - it felt so good, suddenly you realise that for most things model view control is pretty simple to do with a few lines of code and you have the advantage of being able to see exactly what is happening.
1 comments

jQuery's bread and butter is DOM manipulation. However, for even moderately small use cases (even an interactive form) it is useful to use React, Angular, or some data binding framework, as state changes in jQuery quickly become unmaintainable.
It _can_ become unmaintainable but it entirely depends on how you define your view state, you can still create large applications with jquery if you refrain from creating overly complex state UI (speaking from experience). One thing I find overly shunned in favour of heavy MVC is CSS, CSS is a bloody state machine, it's perfect to manage your UI, you need one DOM call to update one piece of state... define the reset in CSS and your MVC UI component suddenly seem over engineered.