web/_includes/lozad.html

11 lines
329 B
HTML
Raw Normal View History

2021-01-25 01:20:51 +03:00
<!--
image lazy load: https://github.com/ApoorvSaxena/lozad.js
-->
2019-12-01 20:15:55 +03:00
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/lozad/dist/lozad.min.js"></script>
2020-05-28 23:51:20 +03:00
2019-12-01 20:15:55 +03:00
<script type="text/javascript">
const imgs = document.querySelectorAll('.post-content img');
2020-05-28 23:51:20 +03:00
const observer = lozad(imgs);
2019-12-01 20:15:55 +03:00
observer.observe();
</script>