A clean and minimal youtube frontend, without all the ads and whistles
JavaScript
handle 404
Christian Feibd659a400dcf
diff --git a/lib/server.js b/lib/server.jsindex c9f79e2..0ddc9dd 100644--- a/lib/server.js+++ b/lib/server.js@@ -49,7 +49,10 @@ export function createServer ({repo, connections = []}) {return fileHandler('client/components/channels-list.js', 'application/javascript')(req, res)if (url.pathname === '/lib/store.js')return fileHandler('client/lib/store.js', 'application/javascript')(req, res)+ if (url.pathname === '/' || url.pathname === '/index.html')return fileHandler('client/index.html', 'text/html')(req, res)+ res.writeHead(404, { 'Content-Type': 'text/plain' })+ res.end('Not found')})function fileHandler (filePath, contentType) {