Inkcite 1.18.3

Image Optimization

Inkcite can automatically optimize all of the images in your email project before uploading to your CDN, mailing a preview or performing a compatibility test. Inkcite uses ImageOptim which runs your images through a variety of optimizers and chooses the best one - ensuring maximum compression and minimal quality loss.

Image optimization is enabled by default in config.yml:

# When true (recommended), enables automatic optimization of GIF,
# JPG and PNG images used in your email.
optimize-images: true

When image optimization is enabled, the source images you save in images/ should be uncompressed or at maximum quality.

When image optimization is enabled, Inkcite will create compressed versions of each image and save them in images-optim. The source files in images/ are never damaged. Inkcite automatically detects when source images are updated and re-optimizes them.

Previewing Optimized Images

When you view your email using the live preview server (e.g. inkcite server) the images you see in-browser are the optimized version.

Per-Image Compression Override

When Inkcite is processing your images, if it finds a .compressed file named after a file in your images/ directory, it tells Inkcite that the image has already been compressed and it should not pass the image to ImageOptim. Instead, the image will be copied directly into image-optim as-is.

For example, if your images/ directory looks like this:

├── images
|   ├── my-compressed.jpg
|   ├── my-compressed.jpg.compressed
|   └── not-compressed.gif

When Inkcite processes the images in this directory, the my-compressed.jpg will not be compressed whereas the not-compressed.gif will be run through ImageOptim.