Refactored to single page app