Created
March 4, 2018 13:00
-
-
Save Colour-Full/906f2009b0795408ad3b6abb7e4d7b8b to your computer and use it in GitHub Desktop.
Keystone Js with React and Redux
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var keystone = require('keystone'); | |
var Types = keystone.Field.Types; | |
// First we gonna create our User list | |
var User = new keystone.List('User'); | |
// Then we gonna add the fields | |
User.add({ | |
name: { type: Types.Name, required: true, index: true }, | |
email: { type: Types.Email, initial: true, required: true, index: true }, | |
password: { type: Types.Password, initial: true }, | |
canAccessKeystone: { type: Boolean, initial: true }, | |
}); | |
User.register(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment