Showing
1 changed file
with
9 additions
and
6 deletions
1 | -const Logger = require('./logger'); | 1 | +const http = require('http'); |
2 | -const logger = new Logger(); | ||
3 | 2 | ||
4 | -logger.on('messageLogged', (arg) => { | 3 | +const server = http.createServer(); |
5 | - console.log('Listener called',arg); | ||
6 | -}); | ||
7 | 4 | ||
8 | -logger.log('message'); | 5 | +server.on('connection',(socket) => { |
6 | + console.log('New Connection...'); | ||
7 | +} ); | ||
8 | + | ||
9 | +server.listen(3000); | ||
10 | + | ||
11 | +console.log('Listening on port 3000....'); | ... | ... |
-
Please register or login to post a comment