Bower and Modularize

Added bower as dependency manager and modulated the code into different
files.