hugo/docs/content
Tristan Rice a49f838cd0 tpl: Add imageConfig function
Add imageConfig function which calls image.DecodeConfig and returns the height, width and color mode of the image. (#2677)

This allows for more advanced image shortcodes and templates such as those required by AMP.

layouts/shortcodes/amp-img.html
```
{{ $src := .Get "src" }}
{{ $config := imageConfig (printf "/static/%s" $src) }}

<amp-img src="{{$src}}"
           height="{{$config.Height}}"
           width="{{$config.Width}}"
           layout="responsive">
</amp-img>
```
2016-11-16 13:00:45 +01:00
..
commands docs: Regenerate commands doc 2016-10-05 10:23:45 +02:00
community docs: Add article by Zetao Yang 2016-11-06 14:33:24 +01:00
content docs: Fix typos in content section 2016-10-24 23:43:28 +02:00
extras docs: Fix typos in extras/scratch.md 2016-11-13 13:45:31 +01:00
meta docs: Update roadmap 2016-11-04 20:18:13 +01:00
overview all: Unify case of config variable names 2016-10-24 20:56:00 +02:00
showcase docs: Remove non-showcase Hugo sites 2016-11-02 19:12:58 +01:00
taxonomies docs: Remove merge artifact 2016-10-17 15:44:05 +02:00
templates tpl: Add imageConfig function 2016-11-16 13:00:45 +01:00
themes docs: Clarify installation of themes 2016-10-22 17:08:35 +02:00
tools docs: Add hugojoomla to the tools section 2016-10-17 15:50:49 +02:00
troubleshooting docs: Add lastmod to content files 2016-01-06 23:55:18 +01:00
tutorials doc: Add a "Deployment with rsync" tutorial page 2016-11-04 17:00:24 +01:00