Adds initializing screen
This commit is contained in:
parent
10cc57afa0
commit
bd3dd6b964
2 changed files with 135 additions and 0 deletions
|
|
@ -56,9 +56,16 @@ const overComplicatedMessage = (ip, port) => {
|
|||
return msg;
|
||||
}
|
||||
|
||||
function send404(req, res) {
|
||||
// send your 404 here
|
||||
res.statusCode = 404
|
||||
res.end('nothing here!')
|
||||
}
|
||||
|
||||
try {
|
||||
connect()
|
||||
.use(serveStatic(`${__dirname}/dist`))
|
||||
.use(serveStatic(`${__dirname}/public`, { index: 'default.html' }))
|
||||
.listen(port, () => {
|
||||
try { printWelcomeMessage(port); }
|
||||
catch (e) { console.log('Dashy is Starting...'); }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue