Web Programming @ MIPT, 2015-2016

Markovtsev Vadim

Media&design

Web Programming @ MIPT, 2015-2016

Image merging

Advantages: single HTTP request, smaller size (in some cases)

PNG optimization

SVG: drawing

SVG optimization

JPEG optimization

Adobe Flash (.swf)

Animated PNG

webp

<picture>

<picture>
  <source media="(min-width: 40em)"
    srcset="big.jpg 1x, big-hd.jpg 2x">
  <source
    srcset="small.jpg 1x, small-hd.jpg 2x">
  <img src="fallback.jpg" alt="">
</picture>

@media

			<link media="screen and (device-aspect-ratio: 16/9) and
  (width>600px) and (pointer) and (scripting)"
  rel="stylesheet" href="example.css">
		

Printer-friendly HTML

<video>: mp4

<video>: webm

<video>: which format to choose?

Typography

Lorem ipsum

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse metus neque, scelerisque quis odio nec, volutpat elementum lectus. Proin ut volutpat tellus. Aenean fermentum, felis et blandit congue, nibh mauris vehicula ante, dapibus vulputate ipsum velit vestibulum odio. Duis nec efficitur quam, nec congue orci. Curabitur eleifend massa orci, vel sagittis odio vulputate et. Proin dignissim faucibus purus at sodales. Duis ultrices nec lorem vitae pretium. Etiam nec euismod felis, non eleifend massa. Etiam scelerisque tincidunt nibh, nec auctor velit ornare nec. Etiam tincidunt, urna in luctus aliquam, quam dui elementum ex, quis pulvinar nisi velit vel leo. Cras pulvinar aliquet orci, in posuere velit finibus eget.

Font formats

woff2 is the defacto standard.

Accessing fonts

Choosing fonts

Iconic fonts

Web design

Next steps

View on Github