Reputation: 11788
In Django i want to know how to see the full objects which may have nested objects like model, formset etc in template as html or <pre>
element
Is it possible.
Because it will help me to debug and check the results.
Upvotes: 2
Views: 2273
Reputation: 1145
I just came up on that question that hasn't the right answer which is using the special built-in template filter pprint
.
# in your template
<pre>{{ my_value | pprint }}</pre>
As said in the docstring, it helps, really.
Upvotes: 7