Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const shared = {
- type: String,
- required: true,
- }
- const SpeciesSchema = new Schema({
- name: {
- common: shared,
- scientific: shared,
- },
- organism: {
- ...shared,
- enum: ["Plant", "Animal", "Other"],
- },
- ...,
- }
Add Comment
Please, Sign In to add comment