Question

Story so far -> We have built an angularjs app which consists of a single html file and few lightweight js files. Entire dom is controlled by angular . However we need to upload audio files and save json objects. Given the nature of data to be sent to and from browser, socket.io and mongoose is no brainer. However I have a doubt between mean.io (http://www.mean.io/) and node-restify(http://mcavage.me/node-restify/#installation) .Both these repos have decent following.

the mean.io uses express and angular.js while node-restify is a pure http json server. I have two options adapt me to mean.io or host the angular.js app using only nginx and make json calls to node-restify and take care of the server communications required. Potentially node-restify seems cleaner but will it give CSRF token issues even if both my static server and the node server nginx configuration share the same server domain

Was it helpful?

Solution

Ideally none of the above. Unless you are building a very simple application like a blog or a TODO list (its amazing how many examples quote these) using any framework like Mean or Meteor(check this one out) is not advisable. Think of it this way these frameworks get you off your feet in no time, but every customized behavior takes time and resembles a hack

So if you have minimalistic CRUD operations anyways to be handled at node end, dont even use a framework. Write your own code, modularize it. The way i see it is that you will end up overwriting default CRUD of any framework sooer or later.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top