What's so bad about running inside a web browser?
1. Search engines cannot crawl your app. Therefore you can forget about SEO.
Consider a simple Todo list app, that lets you list all your todos, enter a new todo, view details of a todo.
In order to support pushState, your backend server needs to know how to render these three URLs as well.
/todos - list all the todos
/todos/new - render the new form to enter a todo.
/todos/123 - show details of a todo.
Most of us, when asked what is a client, we will point to the browser because that is what we have been dealing with for the last 15+ years. But this is now. Can we redefine what a client mean? Can it be the browser combined with Node.js?
Mean while, our backend server only need to handle REST requests. It should not worry about the presentation layer anymore. We can still implement it using Ruby/Rails, Python/Django, or whatever our favorite language/framework is.
Also, we can allow other clients such as iOS, or Android apps reusing the same backend code too! One server, multiple clients!
Anyway, there are two open sourced projects that try to tackle these two problems.
The first one is called DerbyJS. However, it's trying to do too much. It baked in real time communication(websocket), and integrated the database layer(MongoDB). Forcing you to use NodeJS as your backend. (I'm a strong believer of keeping the client code and the server code separated!)
The second one is called Yahoo Mojito. It takes a lighter approach. There is no database integration. It encourages you to use web services to exchange data. Check out its value proposition video. http://www.
Post a Comment