Refactored all the views into separate components, moved scripts to the ...

...bottom of the page