started refactoring diet and exercise javascript to be more modular