use Rails.env to disable js logging in production
added explicit support for a login route
no need to wait for dom load here