Skip to content

Instantly share code, notes, and snippets.

@watzon
Created December 16, 2015 18:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save watzon/e6b23db3fd63ec9fd9ec to your computer and use it in GitHub Desktop.
Save watzon/e6b23db3fd63ec9fd9ec to your computer and use it in GitHub Desktop.
"use strict";
let mongo = require('mongoose'),
Schema = mongo.Schema;
let schema = Schema.new({
name: String,
_date_added: Date.now(),
_date_updated: Date.now()
});
// Sample method for the schema
// schema.methods.foo = function() {
// return true;
// };
var Model = mongoose.model('CHANGEME', schema);
module.exports = Model;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment