Celebrate King's Day with TNW 🎟 Use code GEZELLIG40 on your Business, Investor and Startup passes today! This offer ends on April 29 →

This article was published on March 15, 2011

Create a chatroom in 12 lines of code with NowJS


Create a chatroom in 12 lines of code with NowJS

San Francisco startup Flotype this week released NowJS, a web framework that makes developing real-time apps easier.

The framework essentially allows real-time communication between server-side and client-side code so that they behave like a single program. This simplifies the process of developing complicated real-time applications, such as chatrooms, news web apps and notification systems.

In true startup style, the company was founded by a group of Berkeley drop-outs — Darshan Shankar, Eric Zhang and Sridatta Thatipamala.

Large companies like Quora and Facebook, leaders in the area of real-time Internet, have built proprietary frameworks of this kind, but they aren’t available to the public. Projects like NowJS that make this technology available to all developers could represent a turning point in the next evolution of the web.

Shankar believes we’re at that crossroad now. “I believe that Web 3.0 will be real-time, and we will lead the charge,” he said in an email.

The NowJS framework is built on top of node.js and Socket.io and needs access to a node.js HTTP server instance to function.

NowJS offers a high level of abstraction that can be seen in NowJS’s impressive claim to fame — the ability to write a chatroom app in 12 lines of code. You can check out the tutorial here, and a screencast showing you how to do it right here:

NowJS Introduction: Simple Chat Server in 12 Lines of Code from NowJS on Vimeo.

So how does Flotype plan to profit from NowJS? Shankar says it’s too early to look at monetization, but there are some plans.

“Our speculated business model is a platform-as-a-service. The issues with hosting real-time applications are different from traditional apps. Thus, we would offer an easy, scalable hosting platform for developers similar to Heroku.”

Get the TNW newsletter

Get the most important tech news in your inbox each week.