Extras catalogue

SmushIt

Latest release 3 months ago (July 20, 2026).

smushit

  • By stewartorr

About

This snippet tries to optimise and compress PNG and JPEG images for better performance using the resmush.it optimisation API. This will help massively with Google Page Speed and can reduce image sizes by up to 70%. This will overwrite any existing images so is intended to be used as an output filter after pthumb or similar.As this is a first release, your feedback and requests are welcome.

Installation & usage

Install the package using package manager and you will then need to update your output to use the smushit output modifier.

Snippet smushit

This snippet expects to be used as an output filter in the following format:

This will use pthumb to resize the image and then smush it to optimise the file. The thumbnail image is overwritten once and from then on is optimised. This affects first uncached performance so you should review if this is worthwhile. After caching it runs fine and then helps the page load speed by using the new files.

As this is a first release, your feedback and requests are welcome.

More information available on my blog: https://www.stewartorr.co.uk/smushit

At a glance

MODX 3 compatible.

  • Developer stewartorr
  • Latest release July 20, 2026 (3 months ago)
  • First seen in SiteDash July 20, 2026 (3 months ago)
  • License GPLv2
  • MODX support 3.0 – 100.0

Releases 4 indexed releases

Changelog
MODX.com

2.0.2-pl

July 20, 2026

3 months ago

1. Fix bug with file size comparison not correctly serving optimised images.
MODX.com

2.0.1-pl

February 2, 2026

9 months ago

—
MODX.com

2.0.0-pl

February 2, 2026

9 months ago

—
MODX.com

1.0-beta1

October 25, 2016

10 years ago

<p>Initial content</p>