Adding grunt & re-arranging code