Created
March 31, 2021 17:04
-
-
Save samuchakraborty/0d1b4916a5d74dc7ffbac9ee0ded06f6 to your computer and use it in GitHub Desktop.
This file contains 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
const express = require('express'); | |
const mongoose = require('mongoose'); | |
const bodyParser = require('body-Parser'); | |
const ejs = require('ejs'); | |
const app = express(); | |
app.set('view engine', 'ejs'); | |
app.use(express.static("public")); | |
app.use(bodyParser.urlencoded({ | |
extended: true | |
})); | |
mongoose.connect("mongodb://localhost:27017/wikkiDB",{useNewUrlParser: true, useUnifiedTopology: true }); | |
app.listen(3000, function () { | |
console.log("server is working"); | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment