Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • ludda756/TDDD27
1 result
Show changes
Commits on Source (6)
# Auto detect text files and perform LF normalization
* text=auto
const mongoose = require('mongoose')
const commentSchema = new mongoose.Schema({
profile_name: {
type: String,
required: true
},
profile_picture: {
type: String,
required: true
},
comment: {
type: String,
required: true
},
})
const commentModel = mongoose.model("comment", commentSchema)
module.exports = commentModel
const mongoose = require('mongoose')
const userModel = require('./user')
const postSchema = new mongoose.Schema({
name: {
type: String,
required: true
},
recipe: {
type: [String],
required: false
},
description: {
type: String,
required: true
},
author:{
type: mongoose.Schema.Types.ObjectId,
ref:"user"
},
profile_picture: {
type: String,
required: true
},
profile_name: {
type: String,
required: true
},
upvotes: {
type: [String],
required: false
},
comments: {
type: [mongoose.Schema.Types.ObjectId],
ref:"comment",
required: false
},
photo: {
type: String,
required: true
}
})
const postModel = mongoose.model("Post", postSchema)
module.exports = postModel
frontend/public/content/landing1.jpg

4.3 MiB

import anime from 'animejs/lib/anime.es.js';
export const fadeInVertical = (element) => {
anime({
targets: element,
opacity: [0, 1],
translateY: ['10px', '0px'],
easing: 'easeInOutQuad',
duration: 250,
});
};
export const fadeInHorizontal = (element) => {
anime({
targets: element,
opacity: [0, 1],
translateX: ['20px', '0px'],
easing: 'easeInOutQuad',
duration: 500,
});
};
export const fadeInAndScale = (element) => {
anime({
targets: element,
opacity: [0, 1],
scale: [0.5, 1],
easing: 'easeInOutQuad',
duration: 500,
});
};