Better Titanium Option Dialog

A simple option dialog


I’ve been working with Appcelerator Titanium for over 3 years now and like any piece of software, no matter how great, you tend to expose some lackluster details given enough time. Luckily for developers extensible software lets us take initiative when needed. Obvious points aside, I’ve repeatedly encountered an annoying pattern that arises when creating Ti.UI.OptionDialogs that require conditionalized options.

This is not to discredit Titanium; it is extremely powerful and useful. My point is to expose a common pitfall that I’ve encountered and how I attempt to solve it using a simple module. Let’s go.
Continue reading

HTML Scroll Culling – A jQuery Plugin!

Rendering large, scrollable areas of non-viewable HTML can often times be wasteful and unnecessary – especially in cases where users only view the “tip of the iceberg” of your content. It would be far more efficient (think mobile environments) to only render the content as needed rather than upfront. Enter the concept of back-face culling.

A coworker and I were talking a while back about how to maintain efficiency on a mobile web app when rendering a lot of content. We went back and forth on the topic of rendering content below the fold only when the user specifically begins to scroll to it. Long story short, he mentioned it reminded him of the rendering technique in CGI known as back-face culling. Basically, the rule goes as such: don’t render and waste processing power on things that can’t be seen. Take that and add in the power/convenience of jQuery and we have the jQuery Scroll Cull plugin.

Continue reading

HTML Form Validator: A jQuery Plugin!

A few months back I authored a simple, extensible jQuery plugin for easy form validation. There are plenty of awesome form validation tools out there but I wanted something that could be extensible with customizable validation patterns, customizable callback success/error functions, and something I could learn from :)

If you prefer to just read the source then feel free to fork it on GitHub and have at it. Otherwise, here we go!

Continue reading