Permalink
Browse files
Creating the Todo model with Mongoose
- Loading branch information
Showing
with
9 additions
and
0 deletions.
-
+9
−0
models/Todo.js
|
|
@@ -0,0 +1,9 @@ |
|
|
var mongoose = require('mongoose'); |
|
|
|
|
|
var TodoSchema = new mongoose.Schema({ |
|
|
name: String, |
|
|
completed: Boolean, |
|
|
note: String |
|
|
}); |
|
|
|
|
|
module.exports = mongoose.model('Todo', TodoSchema); |
0 comments on commit
afc9080