Wednesday, June 26, 2013

Kendo UI team made a beautiful AngularJS API

Kendo UI team's first foray on making an AngularJS API for Kendo UI. Angular Kendo UI v 0.0.9


function MyController($scope) {
  $scope.model = kendo.observable({
    var things = [ "Thing 1", "Thing 2", "Thing 3" ]
  });
}

// page
// No need to call bind, the AngularJS directive does it for you
<select id="things" data-role="dropdownlist" data-model="model" data-bind="source: things">
</select>


After pondering their Angular API above and feeling happy but not satisfied, they might have said something along these lines "Darn, that's not intuitive! Let's scrap MVVM observable noises and all that shiznit, JSON objects should be directly bindable to our widgets". Thus upon realizing that, Kendo UI Developer Relations team (their relationship to users/developers must be very important to give their team a name like that) made a second attempt to make their Angular API beautiful and less obnoxious by removing the observable thingie, and let the component users feel the magic by enabling the JSON objects be directly bindable to their Kendo widgets.


Contrast the above API with the following more intuitive API. This is the API that even a CTO would love to develop things around. Angular Kendo UI v 0.5.0


function MyController($scope) {
  $scope.things = [ "Thing 1", "Thing 2", "Thing 3" ]
}

<select kendo-drop-down-list k-data-source="things" k-option-label="'Select A Thing'" ></select>


Happy But Not Satisfied Coding! ツ


Read the rest at: http://www.kendoui.com/blogs/teamblog/posts/13-06-24/announcing-angular-kendo-ui.aspx

Wednesday, June 19, 2013

Web development for non-masochists. Even a CTO enjoys doing it

When a CTO realizes that most web developers are masochists for generating HTML at server-side technologies (I'm looking at you ASP.NET, ASP.NET MVC, JSF, Struts, Spring MVC and whathaveyou), he'll write an article showing us how to reduce boilerplate codes with AngularJS. A CTO can simplify web development and make it looks like a child's play:


"When your CTO goes off on a tangent and writes his own @angularjs directives and whitepaper. http://www.codeproject.com/Articles/607873/Extending-HTML-with-AngularJS-Directives … #wijmo #ComponentOne" -- https://twitter.com/b4nn0n/status/347020882511818752



"AngularJS + Kendo UI Grid: deferred data source, inline editing w/ two way data binding http://plnkr.co/edit/MBjO2QBkpDoqDGD2NDR2?p=preview" -- https://twitter.com/kevinhillinger/statuses/325949992378454016



CTOs should not know AngularJS, it will give them the impression that web development is very easy, the impression is valid however ツ





Happy Coding! ツ

Sunday, June 2, 2013

The Unwritten Rule, or When Should We Use Our Best Judgement

Those who want everything be in written rule, are those who have zero tolerance when some of their colleagues deviate a bit from the project's "standards." Those are the same kind of people who loves to maintain a whitelist of stuff that should be conformed to instead of just maintaining a blacklist of stuff that can't be violated.



The wife, daughter and I went some place and rode a train. There's a designated car(or is it called a coach or carriage?) of the train for women, children and elderly. Even it's not explicitly stated or written, a father can go with his family on that specially designated train's car. And mind you, I'm not an elderly, if you don't believe, you get off my lawn! A whitelist kind of person would love to make it explicit that a father can go with his family on that specially designated part of the train



To make the point more dramatic, imagine you are an employee or when you were/are still a student. It will be annoying as hell if some authoritarian opted for a whitelist of websites you can only visit, instead of just maintaining a blacklist. Does it sit well with you if the internet in your company or home has a whitelist of websites that you can only visit?



The world is abound with very creative people, don't stifle their creativity, don't make it hard for them to hone their craft. Don't make a laundry list of things that they can only do or use; instead, just maintain a list of things that people can't do or use.



So if someone or a colleague said to you, "oh we cannot do that, we have a prescribed list of things that we can only do and should be adhered to", ask the person if he/she is a whitelist kind of person or a blacklist one. And if it could help, ask his/her personality compass. So at least you can understand the person, not that you need/don't need to believe the person, but at least you can understand the person and make the right approach when dealing with them.



#ZeroTolerance policies are absurd because they, by definition, exclude the application of #CommonSense. -- https://twitter.com/bryancostanich/status/337286120851251202



I would rather mentally note 10 things I can't do, than remember 100 things I can only do. I'm not a religious person, but I believe the Bible's Ten Commandments format makes sense, basically it's just a blacklist of things that we should not do, easier to remember and follow. Everything else are mostly subjective