Added grunt debug; externalized directive to template