UNPKG

@mahjongg/mern-mvc

Version:

A CLI that will build a MERN stack application using create-react-app

16 lines (12 loc) 496 B
module.exports = `const mongoose = require('mongoose'); const Schema = mongoose.Schema; const passportLocalMongoose = require('passport-local-mongoose'); const User = new Schema({ name: String //you may replace this 'name' field with anything you like }); //passport-local-mongoose creates a 'username' and some 'password' fields for you //you can add some other fields here too if you like User.plugin(passportLocalMongoose); module.exports = mongoose.model('User', User);`;