In a Laravel Blade template, I can do this to show code only if a user is logged in:
@auth
<div>Show code only if logged in.</div>
@endauth
Does Django have a template tag or something similar that does the equivalent? E.g.:
{% auth %}
<div>Show code only if logged in.</div>
{% endauth %}