move require to top

having require at the top of a module is more common, similar to the java style.I didn't update the bundles. 

@hristoterezov: which browserify version is used/required? Typically specifying that in package.json and writing a build.js script like https://github.com/HenrikJoreteg/SimpleWebRTC/blob/master/build.js is easier in the long run.