A very usefull function in js for downsizing images client side. You can accept big images without fear, this will downsize them before you send them to your server.

The interesting bit of code is in dowsize-image.js, the rest is just for testing. It was tested with 35MB images on chrome, firefox and edge desktop. It was also tested with chrome, firefox and safari on mobile

via https://bookmarks.ecyseo.net/?8IcaYQ (merci coupain !)

            <link rel="stylesheet" href="http://warriordudimanche.net/./plugins/Galart/style.css"/>
                <link rel="stylesheet" href="http://warriordudimanche.net/./plugins/Galart/assets/lightbox.css"/>
                <script src="http://warriordudimanche.net/./plugins/Galart/assets/lightbox.js"></script>
                <script>[].forEach.call(document.querySelectorAll("[lightbox]"), function(el) { el.lightbox = new Lightbox(el);});</script>

✍ Écrire un commentaire

Inutile de poster un commentaire à la con pour vous faire de la pub, ce sera filtré et dégagé direct...

Quelle est la première lettre du mot seff ?