You can integrate Pixboost into web app/site that that has direct access to the DOM, e.g. jQuery, Backbone. This
solution won't work well with frameworks that using shadow DOM, e.g. React, AngularJs.
Some benefits of using library over directly editing HTML and adding picture/img tags:
You can disable optimised images for the whole website or you can enable it conditionally by cookie