Added flashes to js app. Some ux improvements