SPICE/spice-html5 — pull request #1 by mehranhatami (2014-10-16 16:36:20+00:00)
Title: New auto connect scenario, main.js, .jshintrc

> *It is my first contribution to this repo. I started using it in a virtualization project and I found it really amazing and also I saw there are a lot to offer from my background. I am more of a JavaScript nerd than a spice geek.*

In this PR, the old `main.js` file gets renamed to `mainconn.js` and the new `main.js` file has all the inline JavaScript codes we had in `spice.html` and `spice_auto.html`, with some changes like preventing it from creating global variables which is not a good practice in JavaScript.
In the new `main.js` file I also added a new way of having an auto-connect scenario, we can now have auto connection even in `spice.html` file by adding a querystring like:

.../spice.html?auto=1&host=spice-server-host&port=5959

in which `auto` is the main variable to determine if it is a auto connecting process.

I also added `.jshintrc` file to have [JSHint](http://www.jshint.com/) support in the app, although I only made the new `main.js` file JSHint happy, because I thought to get started contributing in this repo, it would be wiser to offer less major changes.

I'd say there are a lot to offer to this repo from my side mostly JavaScript based improvements, and I made this PR mainly to get introduced to you as a contributor.