Several minor code improvements, both JS and Ruby, such as stop using class variables. Also add middleware StaticFiles, which serves static files if the webserver didn't do that. Especially usefull when using local servers as Webrick during development.