If I want to display all resources on a page, I might do:
Resource.find({}).exec(function (err, resources) {
res.render("view", {
resources: resources
However, what if I want to display all resources and all projects on the page simultaneously? I could do:
Resource.find({}).exec(function (err, resources) {
Projects.find({}).exec(function (err, projects) {
res.render("view", {
resources: resources,
projects: projects
I think that there has to be a better/more correct way to do this, though.