diff options
author | ache <ache@ache.one> | 2018-04-13 12:06:02 +0200 |
---|---|---|
committer | ache <ache@ache.one> | 2018-04-13 12:06:02 +0200 |
commit | e1aded8b57736a0532804693c8cafcdb0c497a7f (patch) | |
tree | e9103e9c5ddf0db76fc00009b6da24ad5cff424d | |
parent | Creation d'un package rollup Buddle Web Editor (diff) |
Integration of the bundle editor
-rw-r--r-- | app.js | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -102,7 +102,15 @@ app.get('/', (req, res) => { res.send(data); }); }); - +app.get('/edit', (req, res) => { + console.log(`[${new Date()}] > ${200} - ${req.url}`); + fs.readFile('public/edit.html', 'utf8', (err, data) => { + if (err) { + return console.log(err); + } + res.send(data); + }); +}); app.get('*', (req, res) => { console.error(`[${new Date()}] > ${404} - ${req.url}`); fs.readFile('public/404.md', 'utf8', (err, data) => { |