Quit Yo Jibba-Jabba And…

Continue reading

Editorial: SDK Frustration – My Experiences with Android, iOS, BB, PhoneGap and others

Through my computer science university experience, my need to download SDK’s was limited. Much of our work was done in Java and so the biggest requirement was to download and install Eclipse and the Java JDK. I was fortunate to be able to take a course in iOS development at university as well (one of the best courses I took by far). The setup experience for iOS development is similarly simple. Just download and install the iOS SDK. XCode and all the other tools are automatically configured and prepared for you. You just open XCode and start coding. I found these setup experiences to be generally quick and painless. I recently needed to test a PhoneGap application in an Android context. I had never done so before and I, perhaps naively, expected the setup to do so to be equally as painless as I had experienced before. Wow was I wrong.

Continue reading

jWorkflow: A JavaScript Workflow Framework

Dude Where’s my workflow?

While working on large javascript projects at tinyHippos we would commonly end up with a rather complex bootstrapping process where we need to execute a large amount of initialization code in a specific order. Some of this code is asynchronous and some is synchronous.

We would start out with a series of events and function calls to attempt to chain together the bootup but it would quickly become hard to inject in new tasks. This prompted us to use the tinyHippos mantra “There has to be a better way”.

Continue reading

Some Observations On Asynchronous Programming In Client Side JavaScript

Programming operations asynchronously in client-side JavaScript can make life a lot easier. Lately, I found myself wondering what async truly means in this case, did some investigations and figured it would be worth mentioning.

Continue reading

Closure in JavaScript – with examples

Here at tinyHippos, we use JavaScript extensively. As a matter of fact it is our core development language right now. So I’m often surprised to see how many developers don’t understand how closure works. There are some great resources out there that I recommend every JavaScript developer read / watch and I’ll post them all at the bottom of this article.

I wanted to start this article with the actual definition for closure, so I went where everyone goes: Wikipedia :-) Here’s what they have to say about closure:

“In computer science, a closure is a first-class function with free variables that are bound in the lexical environment. Such a function is said to be “closed over” its free variables…”

Well then… that statement really confused me, I mean seriously… a closure is said to be “closed over”, brilliant! Let’s try and define closure in plain English and let’s first look at the two major requirement that a language must implement to be able to have closure.

Continue reading

Modular Programming Patterns With JavaScript

These days, if you search around the web even a little, you will eventually come across many examples, tutorials, code snippets, libraries and more on JavaScript (i.e EMCAScript). Unfortunately it being a very flexible and easy to learn language, a good bunch of it is is not an ideal example of good practices. Then again a lot of the examples are very helpful too. Best bet, go to the library, bookstore, amazon or any other veritably knowledgeable source, and do some reading. Don’t forget to get your hands a little dirty by writing some code too!

For those of you that have been trained/educated in using classical object oriented languages, JavaScript will feel a little foreign. And, if you’re like we were when we first started using JavaScript as our platform, you’ll want to apply your OO knowledge to JS… please don’t, you’ll just hurt yourself :-)

In this article we’re going to present our favourite way of creating objects and doing inheritance. Keep in mind, this peg will not fit into just any size hole. Take the time to learn JS and then apply the patterns that match your needs best. We recommend this book to get started:

JavaScript: The Good Parts (very short book, and a must read)

Continue reading

Follow

Get every new post delivered to your Inbox.