Create a CRUD App with Node and MongoDB: Lesson 12 of 17

Showing Real Events

Up Next

Creating Events

Autoplaying in 7 seconds!


We'll use mongoose and the mongoose model we created to grab real events from our MongoDB database.

To grab events:

// grab all events, the {} matches all
Event.find({}, (err, events) => {



// grab a single event with the slug ping-pong
Event.findOne({ slug: 'ping-pong' }, (err, event) => {



Chris Sevilleja

168 posts

Co-founder of Slapping the keyboard until something good happens.