News for hackers. Stuff that matters.
Re:Learn AngularJS by tomjen3 on Friday April 03, 2015 @11:28AM (#9316391)
Sadly that library misses the point: MVVM. With angular I get to tie my user interface to my model in a declarative way, my model doesn't really have to be anything but a simple javascript object, I can use straight html to design the interface and when something changes I don't have to think about it.

If you haven't ever worked with MVVM, do so. It is a treat.

Re:Learn AngularJS by lhorie on Friday April 03, 2015 @12:15PM (#9316684)
Hi, Mithril author here.

`ng-model` is actually one of the "magic" things that @hippich is warning against. Having used Angular (and built Mithril based on lessons learned from using it for a few years), I agree bindings are handy in a lot of cases. That is, until you need to work around them (maybe because your inputs are laggy, or you've hit the infamous 2000-binding-ceiling, or whatever). Then, they're not such a treat anymore.

With Mithril (and fwiw, other virtual dom libraries as well), you can choose to add the convenience of bindings where you find appropriate.

The points about POJOs and HTML syntax are, similarly, aspects that you have control over.

Re:Learn AngularJS by mahmud on Friday April 03, 2015 @01:46PM (#9317266)
Update the copyright year of the mithril site footer; it still says 2014.
Re:Learn AngularJS by davexunit on Friday April 03, 2015 @11:32AM (#9316416)
>Sadly that library misses the point: MVVM.

I don't understand. Mithril also allows for clean separation of view and model, typically in a functional and declarative manner.

>If you haven't ever worked with MVVM, do so. It is a treat.

I worked with it for quite some time at a past job which gave me my strong opinions about the uselessness of Angular.

Re:Learn AngularJS by misterbwong on Friday April 03, 2015 @11:53AM (#9316536)
Agreed. I want to say grandparent actually means automatic two-way model binding, not MVVM.