No commit activity in last 3 years
No release in over 3 years
Optimizes images during middleman build using image_optim gem
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.12
~> 10.0
~> 3.0

Runtime

 Project Readme

Middleman::ImageOptim

Automatic image optimizer for Middleman v4 using image_optim gem.

Installation

Install image optimizers supported by image_optim, and then enable middleman-image_optim gem in your Middleman project.

gem 'middleman-image_optim'
gem 'image_optim_pack'  # optional -- some optimizers can be installed with this gem

Usage

Activate image_optim extension in your Middleman configuration. Refer to the image_optim documentation for available options.

configure :build do
  activate :image_optim,
           cache_dir: File.join(__dir__, '.cache', 'image_optim'),
           jpegtran: true,
           optipng: true
end

License

The gem is available as open source under the terms of the MIT License.