Refactored Browserify transformer

Refactored transformer.js and moved from lib/ to src/