Hacker News new | past | comments | ask | show | jobs | submit login

For node-based API backends, I've been using Sails.js or Deployd. In addition to providing automatic RESTful CRUD APIs for your data models, both Sails and Deployd also provide WebSocket interfaces that make it really easy to support real-time capabilities without doing any extra work. It doesn't look like LoopBack does that.

I've been particularly happy with Sails.js as the backend framework for my single-page web apps. I get rid of the Sails view system and use it solely as an API backend. The current 0.10 beta, which adds support for associations in data models, is really nice.




I've been considering using Sails to redo a simple RoR project--mostly to help decrease the number of languages floating around in the project.

Any thoughts/gotchas from your experience with it?


* The Sails ORM (which is called Waterline) is very light and simple, but it doesn't have the maturity or the same degree of expressive power that you get with ActiveRecord. Associations were recently added and the query system doesn't really let you take advantage of them quite yet.

* There are also subtle differences in behavior that emerge when you use Waterline with different database adapters, so you really need to develop against the same DB adapter that you intend to use in production.

* When you need to customize the behavior of the CRUD methods that Sails gives you by default (like if you need to transform some parameters passed in by the user in the create method), it is often cleaner and easier to do it by applying custom policy methods rather than overriding the actual CRUD method in the controller.

* For a new Sails project, you probably want to start with the new version 0.10 even though it hasn't been officially released yet.

Those are the points that first come to mind. Despite the limitations, I've found it to be a pretty compelling framework. And it's very actively developed, so a lot of the deficiencies are being corrected.


Thank you!


both are great frameworks, Ritchie was one of the originators of Deployd, LB incorporates lessons learned from Deployd. We have the same WebSocket interface for LoopBack through strong-remoting to support real time. We haven't had time full bake it in, but will soon, especially now finishing up sync and needing server to device push.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: