Archive of

SimpleWebRTC.js: Maybe Not So Simple

I've been playing around with SimpleWebRTC.js and the very interesting-looking Talky website, which allows anyone to create a video chat room on-the-fly by entering it in a form or putting the name of the room at the end of the URL. I also looked at the SimpleWebRTC demo, because it seems to be a simpler version of Talky that I could use to get started. Apparently, something like this is extremely easy to implement, and can be set up in as little as 5 minutes. Sadly, it seems they were exaggerating just a bit when they said it could be set up in 5 minutes.

SimpleWebRTC.js

According to the website, SimpleWebRTC.js is a very simple modular library that allows developers to get a very basic WebRTC application up and running quickly and easily. There is some very basic documentation on the front page of the site that shows just how easy it can be, and a link to fork it on GitHub. All good so far. So I figured it would be fun to put a copy on my vps and play with it there. But the HTML and JavaScript on the page for some reason didn’t work for me. No problem, I decided that just for testing purposes, I would rip the source from the demo page. After all, it works there, so it should work on my VPS with minimal modifications. No such luck. Every time I enter anything into the form that is presented on the page, it just loops back to the same page with the same form, unlike the demo, which reloads the page, attaches the room name entered from the form to the end of the URL and appears to start the WebRTC chat room.

SignalMaster

The SimpleWebRTC.js website does mention that if I’m planning to do anything other than development or testing, I need to set up my own signaling server. It recommends using a very small JavaScript library called SignalMaster. Fine, at this point, I’m thinking that my problems are caused by the fact that my copy of simplewebrtc.js is still configured to use the development signaling server that is provided for demo/testing purposes only, so I decided to try SignalMaster. And now I find an entirely new problem. I have read just about all there is to read about SignalMaster, which only has a GitHub page and a couple of very short blog posts around the internet, none of which tell me how I’m supposed to get this thing running as a server listening on a port. I did see something that mentioned that I may need node.js, but there were no instructions on how to get the server up and running. In the SignalMaster source tree, there are only 2 json files, a server.js file and the README.md file that shows up on GitHub, which contains very little other than a very short explanation of what it does.

Conclusion

I like the idea, and I like the fact that it's open source, but it took less time to write this rather extensive blog post than it took to find out that there was no way I was going to be able to make SimpleWebRTC.js work on my server. So I guess since it took me several hours of messing with this thing only to find that something that is said to be usable within 5 minutes doesn’t work at all no matter what I try, and since there is too little documentation on how to make the signaling server run, I will have to table this project for now, and hope that the situation will improve with time.


Markdown in comments

As some of my readers may be aware, I am a huge fan of Markdown, because it makes writing much easier, and because it is human-readable. After all, people have been writing email using something very similar to ([Markdown syntax]https://daringfireball.net/projects/markdown/syntax) since before Markdown was created, so the transition is quite natural.

I never would have moved my blog to WordPress if not for the Markdown On Save Improved plugin, because I was quite accustomed to writing my posts using Markdown. A big thankyou goes out to Matt Wiebe for putting all the pieces and parts together that make this version of the plugin truly rock!

Now for the good stuff for everyone else. For the first time in it’s 4-year history, The Kyle File now supports Markdown in comments, thanks to Evan Solomon's GitHub-Flavored Markdown Comments plugin, so everyone who reads my posts can easily write comments using Markdown syntax. If you have been writing your comments in plain text or HTML, don’t panic, nothing has changed for you. This is just a third option that can make adding links, lists, headers and other nice formatting to comments much easier. Go ahead and try it out by adding a comment on this post. Have fun!