After starting to work with sails.js, I’ve become addicted, and I’ve decided to build a mobile application based on this framework. This means, that the backend consists of Sails.js (which means node.js plus express.js) and MongoDB, and also a Redis store to handle session data and socket connections. Everything is hosted in the cloud: Heroku, Mongolab and Redis Cloud make up the backend. The front end is a CSS3 / HTML5 SPA (Single Page Application) built with Backbone.js, jquery and the latest Phonegap / Cordova release.
Why is it important to mention that this app runs the latest Phonegap release? Because this one has the brand new support for Firefox OS. It should be quite easy to create a bundled app for my Firefox OS phone from that too.
But the app itself is not only a technology showcase, it also has a real world application: let’s call it “anonymous dating by profile pictures”, even if that sounds a bit contradictional at first. The process is simple: you register using Facebook Connect and the app will immediately pull in your latest profile pictures, friends and likes via the Facebook Graph API. After that it starts searching people nearby – preferably searching women, if your gender is male and searching men, if your gender is female. But you can change this at anytime in your settings, as well as the radius for your search.
The people that are found, are shown to you as a polaroid like picture that you can swipe to the left to “dislike” and swipe to the right to “like”. But no worries: nobody will now your decision. Only if the other person likes you too, you will get a message that you have a match and can start a conversation via the apps chat function.
As simple as it sounds, this app has put some serious technological challenges on me. Especially the 1:1 chat function, which uses socket.io (via sails.js) had to be combined with a push notification system. This means that the client (aka the app) has to listen to push notifications and the server should send push messages to a cross platform service (puship.com) when certain events occur.
Experimenting and having to write my own server side code to serve messages to puship.com killed a day or two, but now it’s up and running and really giving me a blast (even if there are only family members using the app for now).
Anyway, here are some screenshots and don’t be amazed if a couple of things look familiar ;-). And, btw, the name of the app is “jigglr”. If you want to apply for the beta, just let me know in the comments.