Live data from Hacker News

Sails.js: Realtime MVC framework for Node.js

balderdashy.github.com

1–10 of 107 posts

Re: Sails.js: Realtime MVC framework for Node.js

#4
This looks incredibly cool, but if there is one thing that I've learned, it's that less magic is generally better when building a real production application (vs a weekend project). While typing something like 'sails generate model User' is nice, I literally have no idea what that just did. In the video it then shows a user creating new attributes on the model via a REST API - what??(he even mistakenly adds a bad attribute and then proceeds to just leave it there...).

After working with a few of these frameworks it always seems to lead to spaghetti code where the code I write weaves in and out of the framework at different pre-defined connection points (Sails calls them policies I think). I always take note of all the times the developer says 'automatically', these are all the places that will break when my requirements don't exactly match up with theirs.

Re: Sails.js: Realtime MVC framework for Node.js

#6

This looks great! The automatic API generation is a killer feature that makes me want to try this out sometime soon. Only thing that seems strange to me is adding the /create, /update, and /destroy GET endpoints -- why not keep it RESTful?

I can see the desire to be able to execute non-GET commands via the browser's address bar. Another way Sails could accomplish that would be to accept "?method=PUT|POST|DELETE" to mimic the desired HTTP method.

Re: Sails.js: Realtime MVC framework for Node.js

#7
post #6

This looks great! The automatic API generation is a killer feature that makes me want to try this out sometime soon. Only thing that seems strange to me is adding the /create, /update, and /destroy GET endpoints -- why not keep it RESTful?

I can see the desire to be able to execute non-GET commands via the browser's address bar. Another way Sails could accomplish that would be to accept "?method=PUT|POST|DELETE" to mimic the desired HTTP method.

I don't think that solves the underlying problem of side effect-ful/dangerous GET requests that may be easily exploited via CSRF attacks. You really don't want to expose POST/PUT/DELETE actions via GET.

Re: Sails.js: Realtime MVC framework for Node.js

#8

I wish more people would read this blog post before writing another MVC framework in Node. http://eflorenzano.com/blog/2010/09/27/why-node-disappoints-...

It looks like Sail.js is a pretty good response to that blog post. It doesn't go all the way of his dream framework, but it also isn't just another straight "Sinatra/Django/Rails" clone.

Re: Sails.js: Realtime MVC framework for Node.js

#9

I wish more people would read this blog post before writing another MVC framework in Node. http://eflorenzano.com/blog/2010/09/27/why-node-disappoints-...

Except without leveraging those V8 features, we don't have what makes node.

The pace of invention today is based on iteration, building upon other successes and similar ideas - and its happening in real-time across a vast community. This is awesome.

Personally, I love that we have choices like derby, meteor and potentially, sail. Every effort has pro's / con's that may or may not be ideal for a particular use case. I would rather have more options than none.

Re: Sails.js: Realtime MVC framework for Node.js

#10
Cool, looking forward to watching the projects progress!

Quick question: when demonstrating the socket.io piece, one aspect that differs with meteor is their ddp which only sends data diffs on a per client basis, not the entire subset as your demo showed. How are you planning to tackle that with any decent about of clients or data size?

Post reply on HN