In my Rails application, I can use byebug in the controller.
However, not adding byebug
or console
to the field of view helps me get a debug console.
I use Haml, so this is not <% console %>
. In other words, the lines (one of two in time) that I used in the view are as follows:
byebug console
I have not tried Pry or Pry-debug, but apparently they also do not work in views?
Am I using these gems incorrectly or is there another way to add debugging in the views?
Thanks, Kumar.
Kumar source share