About Images for Retina Displays

To define retina-display version of an image use the srcset attribute:

1
2
3
4
5
{% load static %}
<img src="{% static 'site/img/low-res.jpg' %}" 
     srcset="{% static 'site/img/high-res.jpg' %} 2x"
     alt=""
/>

Tips and Tricks User Experience Optimization Django 3.2 Django 2.2 Django 1.11 Django 1.8 HTML5