Toggle navigation
Toggle navigation
This project
Loading...
Sign in
임태민
/
Mapmory
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
임태민
2021-05-10 18:00:52 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
959949a5a9b0c2922a5def05b7f548d9a7bcbae9
959949a5
1 parent
36f3e637
Update app.js
- Add ejs
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
1 deletions
Mapmory/app.js
Mapmory/package-lock.json
Mapmory/package.json
Mapmory/app.js
View file @
959949a
...
...
@@ -3,6 +3,12 @@ const bodyParser = require('body-parser');
const
session
=
require
(
'express-session'
);
const
app
=
express
();
app
.
set
(
'views'
,
__dirname
+
'/views'
);
app
.
set
(
'view engine'
,
'ejs'
);
app
.
engine
(
'html'
,
require
(
'ejs'
).
renderFile
);
app
.
use
(
express
.
static
(
'public'
));
app
.
use
(
bodyParser
.
json
());
app
.
use
(
session
({
...
...
@@ -14,7 +20,7 @@ app.use(session({
//Home
app
.
get
(
'/'
,
function
(
req
,
res
){
res
.
send
(
"Home page
"
);
res
.
render
(
"index.html
"
);
})
//login
...
...
Mapmory/package-lock.json
View file @
959949a
This diff is collapsed. Click to expand it.
Mapmory/package.json
View file @
959949a
...
...
@@ -10,6 +10,7 @@
"license"
:
"ISC"
,
"dependencies"
:
{
"body-parser"
:
"^1.19.0"
,
"ejs"
:
"^3.1.6"
,
"express"
:
"^4.17.1"
,
"express-session"
:
"^1.17.1"
,
"mysql"
:
"^2.18.1"
,
...
...
Please
register
or
login
to post a comment