Skip to content

Instantly share code, notes, and snippets.

View Athira2199's full-sized avatar
🎯
Focusing

Athira.V.Ajit Athira2199

🎯
Focusing
View GitHub Profile
<!-- navabar sample bootstrap-->
<header>
<nav class="navbar navbar-expand-lg navbar-light bg-light">
<a class="navbar-brand" href="#">Navbar</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav">
<li class="nav-item active">
<!-- footer sample bootstrap-->
<footer class="footer">
<div class="container">
<span class="text-muted">Place sticky footer content here.</span>
</div>
</footer>
<html>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title>Trying out partials in ejs</title>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<body>
<%- include('navbar.ejs') %>
<main role="main" class="container">
What is Lorem Ipsum?
Lorem Ipsum is simply dummy text of the printing and typesetting industry.
const timeLapsedSince = (createdOn)=>{
let lapsedTime = new Date().getTime()-new Date(createdOn).getTime() // time in milliseconds
// time in days
let timeInDays = lapsedTime(86400 * 1000)
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
.line{
animation: line-length 3s ease-in-out infinite;
}
#hand-boy,#hand-note-boy{
animation: rotate 3s ease-in-out infinite;
}
@keyframes line-length{
0%{
transform : translate(-90.21711px,-178.25098px);
opacity: 0.1;
const mongoose = require('mongoose')
var bcrypt= require('bcrypt')
const UserSchema=mongoose.Schema({
name : {
type : String
},
password : : {
type : String
}
})
const user = new User({
name,
password
})
await user.generatePassword()
/* we can write as many method functions in between as well*/
await user.save()