Optimisation Addon
The optimisation addon optimises the markup for performance. This includes:
- Adding recommended HTTP headers for caching
- Minimising the CSS
- Annotating width and height on an image (if no width or height have not been explicitly set)
Auto Image Width and Height Decoration
When it comes to delivering images over multiple channels the physical image that you deliver might vary between different devices. When you, as a site developer, come to add an image it may be handy to think in logical terms and not have to worry about the actual physical dimensions of a devices, e.g. you may say
<img src="/images/myimage.jpeg"/>
When bemoko actually delivers the HTML to the device, the optimisation addon ensures that the correct width and height are set, e.g.
<img width="164" height="35" src="/training/images/myimage.jpeg">
Note also that the default URI rewriting function in bemoko also qualifies the URI to the server relative version, i.e. /images/myimage.jpeg automatically becomes /training/images/myimage.jpeg.