1
0
mirror of https://github.com/matt-fidd/stratos.git synced 2026-01-01 23:19:29 +00:00

Set up homepage template and route

This commit is contained in:
2022-01-24 10:15:17 +00:00
parent e44f82cb50
commit fc00ecd2c5
2 changed files with 13 additions and 0 deletions

4
app.js
View File

@@ -50,6 +50,10 @@ async function main() {
}
}));
app.get('/', (req, res) => {
return res.render('index');
});
// If the request gets to the bottom of the route stack, it doesn't
// have a defined route and therefore a HTTP status code 404 is sent
// and an error page shown

9
views/pages/index.ejs Normal file
View File

@@ -0,0 +1,9 @@
<!DOCTYPE html>
<html lang="en">
<head>
<%- include('../partials/head', { title: 'Stratos - Home' }) %>
</head>
<body>
<h1>Homepage</h1>
</body>
</html>