Populate Backbone Marionette Views with data from Mongoose using Express Route Populate Backbone Marionette Views with data from Mongoose using Express Route mongoose mongoose

Populate Backbone Marionette Views with data from Mongoose using Express Route


Not sure if this will work for your situation but on your collection, add a parse method that accepts your data. You may have a nested array that Backbone isn't able to retrieve the internal data from.

parse: function(data) {  return data[0];}

I would add a debug point inside this parse method to see if the data being passed in is nesting the data.


Nowhere in the code you've posted have you actually fetched your collection from the server.

Attempt this:

var catCollection = new MyCats();catCollection.fetch();var angryCatsView = new AngryCatsView({collection: catCollection});angryCatsView.render();


Problem was this... var thecats= myCats(); thecats.fetch(); Hope it helps someone