Q:

Node.js: Returning proper JSON from mongoose query

I  have this express application with mongoDB as the database and handlebars as my server-side templating engine. I am not using AngularJS or Ajax in my application.
In one of the routes, I have to render the page as well as send over a json file from the database. However, I am not able to achieve this.
Here is code snippet the  my route:
router.get('/disks', function(req, res, next) {
  places.find({"category": "disks"}, function(err, disks){
      if(err){
        throw err;
      }

       res.render('disks', 
        { 
          'risime': JSON.stringify(disks)
        });
      console.log(disks); // PROPERLY LOGS TO THE CONSOLE
  });
});

In the hbs, I am trying to capture it, but I don't even think that it is JSON. 
Here is how it gets logged in the client side:
[{&quot;_id&quot;:&quot;5704630a7d4cd367f8dsdce7&quot;,&quot;name&quot;:&quot;Seagate&quot;,:&quot;This awesome Hard disk&quot;,&quot;,&quot;categories&quot;:[&quot;SDD&quot;,&quot;256GB&quot;]}]

What is the issue and how do I resolve it?

A:

It's handlebars that "html escapes" your string (which is what you normally want). 
if you don't want that, you can use the "triple-stash" notation, like this:
{{{risime}}}

You can read about this here: http://handlebarsjs.com/#html-escaping

