refactoring to work with browserify
changed React files to use Browserify