Created
January 16, 2018 16:40
-
-
Save ilagnev/da7b67ce5e83386f63173bfe98346138 to your computer and use it in GitHub Desktop.
lazy test task solution for nodejs course
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const WebSocket = require('ws'); | |
const rpn = require('rpn'); | |
const ws = new WebSocket('ws://rpn.javascript.ninja:8080'); | |
ws.on('message', data => data.includes('Token') && !console.log(data) || ws.send(rpn(data))); |
Author
ilagnev
commented
Jan 16, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment