aboutsummaryrefslogtreecommitdiff
path: root/index.js
diff options
context:
space:
mode:
authorMateja <mail@matejamaric.com>2021-05-02 21:06:06 +0200
committerMateja <mail@matejamaric.com>2021-05-02 21:06:06 +0200
commit7483bb5da6b22b94045a309d2ece2ed80ce48dc2 (patch)
tree2bcdb9c0e395ab967302fc1409b205f75b0a4f13 /index.js
parent4320439bb76922c13917845a2dcb17a84fc493d2 (diff)
downloadnode-playground-7483bb5da6b22b94045a309d2ece2ed80ce48dc2.tar.gz
node-playground-7483bb5da6b22b94045a309d2ece2ed80ce48dc2.zip
Add `public` directory for static files.
Diffstat (limited to 'index.js')
-rw-r--r--index.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/index.js b/index.js
index b7eb95b..9866dde 100644
--- a/index.js
+++ b/index.js
@@ -6,6 +6,8 @@ const app = express();
app.engine('handlebars', exphbs());
app.set('view engine', 'handlebars');
+app.use(express.static('public'));
+
app.get('/', (req, res) => {
res.render('home', {
title: 'Home Page',