Wednesday, November 30, 2011

I came across this great article on the future of Silverlight. I'm guessing the same thing can be said about Flash. It's interesting to see how technologies that are widely adopted slowly end their life cycle when disruptive technologies appear. Those disruptive technologies (i.e. HTML 5 and JavaScript) usually don't appear overnight, and it takes a while before they are fully adopted. In the end, it's all about reliability, security and performance.

Tuesday, November 29, 2011

Thoughts on JQuery Mobile

I recently had the opportunity to use JQuery Mobile. I've got to say it's a great product, and even though the first release just came out, it's stable and robust. However, if you're going to use it you need to consider that it has some quirks, and you'll need to resolve those manually until they get fixed in the next release (which come out really often, maybe once a month lately). Still, the advantages outweight the disadvantages.

The most important thing you get is a cross-platform framework that leverages development over customization. Yes, you might need to spend more time in UI development than functionality, but at the same time it allows you to deliver functionality quickly and get feedback from your clients. The analogy that comes to my mind is building blocks: JQuery Mobile provides you with pieces of code that you just need to put together!

Sunday, November 20, 2011

Copy and Paste is evil

I consider copy and paste of code one of the most common sources of bugs and bad coding practices. First of all, let's talk about bugs. If you copy and paste code, it's likely you're doing it because you don't know what the code is doing; you only know that it works. You only know that it works, and copying and pasting is easier than re-typing. However, adding code without knowing what it does is a recipe for disaster. A couple of days ago I spent 5 hours troubleshooting code that another developer "copied and pasted". If you're going to copy and paste, at least make sure that you read the code you just copied and pasted.

Moving on bad coding practices. Well, this is an easy one. Duplicate code means that any change needs to happen in 2 different places, and you don't want that. You want classes with clear boundaries, otherwise your code will soon become a big ball of mud.