reorganizing some of the front end stuff for easier reusability