All articles tagged as:


Introduction to Sails.JS ORM queries, part 2

In my previous post, I wrote about Sails.JS ORM which includes model definitions, joins, attributes and such. In this post, I will go over some simple and more advanced queries that will use the previous examples as a basis for our ORM queries. For a more comprehensive list of queries, check out the GitHub documentation for details. Sails.js uses Waterline out of the box as its ORM (object relational mapper) and it's basically an object-based way of querying the database. We created the models with a set of attributes, types, etc so it can be used as a 1:1 object representation of table/docume…

Read more »

Facebook authentication using machinepacks in Sails.JS

When I got first started with Node.JS about two years ago, I came across Sails.JS and instantly fell in love with it. Two years later, it is still my "go-to" web framework when building a Node.JS application. If you're not familiar with Sails.JS, it provides a real-time MVC framework on top of Node.JS. It's basically the ASP.NET MVC for .NET or Rails for Ruby. While it has some pretty nice features out of the box (ie real-time capabilities using websockets, asset pipeline, CLI tools, etc.), the main selling points for me were the built-in conventions and solid, well-thought architecture. For e…

Read more »

Deploying Sails.JS to Heroku

I've been interested in Node.JS for quite some time now but I haven't really realized its potential or find a use case. The extent of my experience was basically creating a quick Express.JS app and see it run in the browser. No formal development whatsoever. I have come across Sails.JS in the past but that's when Node was just in its early stages, or at least before I was interested in the platform. Sails.js coincides with or sits on top of Express.JS using the same MVC pattern as Rails. I watched the introduction video again for Sails.JS today and was amazed at how powerful it is. The ease…

Read more »