fill app.js with helper methods