diff options
author | Paul Duncan <pabs@pablotron.org> | 2022-01-27 22:47:40 -0500 |
---|---|---|
committer | Paul Duncan <pabs@pablotron.org> | 2022-01-27 22:47:40 -0500 |
commit | 387a868e2e1d59eda16c4ad78f3550c54c669ab5 (patch) | |
tree | f6df98af644dbda748e9e8691e863663730223b2 | |
parent | b03a2e23b7080730a06cdbdb26ff72f6e5aaff1f (diff) | |
download | pablotron.org-387a868e2e1d59eda16c4ad78f3550c54c669ab5.tar.bz2 pablotron.org-387a868e2e1d59eda16c4ad78f3550c54c669ab5.zip |
README.md: add img minification
-rw-r--r-- | README.md | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -83,6 +83,16 @@ To serve this site locally: * `--disableFastRenderer` may be unnecessary, but the fast renderer cache was giving me grief while doing theme development. +## Minify Images + +Notes: + +1. Use `svgmin` to shrink [SVGs][svg]. +2. Use `convert -quality 100 -define web:lossless=true foo.{png,webp}` + to compress existing PNGs as `webp`s. +3. Use the `pe-figure` shortcode for progressive enhanced `figure` tags + with a fallback image. + ## Deploy Site To clone site repo: @@ -119,6 +129,8 @@ Includes the following shortcodes: * `table`: Enhanced [CSS][]-only table shortcode. See [hugo-shortcode-table][]. * `sup`: Superscript. +* `pe-picture`: Progressive enhancement `picture` shortcode. +* `pe-figure`: Progressive enhancement `figure` shortcode. `hugo-pt2021` is depends on the following: @@ -164,3 +176,5 @@ The [Bulma][] [SASS][] is: "Scalable Vector Graphics" [hugo-shortcode-table]: https://github.com/pablotron/hugo-shortcode-table "CSS-only table shortcode for Hugo." +[hugo-shortcode-pe]: https://github.com/pablotron/hugo-shortcode-pe + "Progressive enhancement picture and figure shortcodes for Hugo." |