Skip to content

Commit

Permalink
Plug Debugger wrap exception text (#1241)
Browse files Browse the repository at this point in the history
Sometimes exceptions print out with really long lines which makes it
difficult to read the exceptions on the error page.
  • Loading branch information
axelson committed Aug 26, 2024
1 parent 2f00897 commit 9037502
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/plug/templates/debugger.html.eex
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,13 @@
.exception-info > code {
line-height: 1.5;
font-size: <%= :math.pow(1.3, -1) %>em;
}
.exception-details-text {
white-space: pre-wrap;
}
/*
* Code explorer
*/
Expand Down Expand Up @@ -681,7 +686,7 @@
<small>at <%= h method(@conn) %></small>
<small class="path"><%= h @conn.request_path %></small>
</h5>
<code><pre><%= h @message %></pre></code>
<code><pre class="exception-details-text"><%= h @message %></pre></code>
</header>

<%= for %{label: label, encoded_handler: encoded_handler} <- @actions do %>
Expand Down

0 comments on commit 9037502

Please sign in to comment.