IBM Responsive Web Design (RWD) Best Practices Guide

This document describes the best practices for responsive web design.


IBM Responsive Web Design (RWD) Best Practices Guide - cover page
Brand
IBM
Category
Programming
Document type
Other
Language
English
Pages
11
File format
PDF
File size
1.3 MB
Published
03 December, 2023
Updated
03 December, 2023
MD5 checksum
132A89AD0E9E63D6CF5EB1D2B5CE37D5

About this manual

This IBM guide, marked version 2013.11.20 and copyrighted 2013 by International Business Machines, collects best practices for responsive web design (RWD) when developing hybrid applications. It opens with a practitioner checklist and a list of common RWD problems, then discusses each item in a longer technical section aimed at CSS experts and web developers.

The discussion covers using CSS3 media queries instead of JavaScript orientationchange events, flexible font units (em and rem), fluid grid systems, flexible margins and padding, responsive images, media query features and the viewport meta tag, limitations of media queries, breakpoint planning, CSS Flexbox, and workarounds for complex components such as calendars, charts and grids that need a JavaScript call to resize or redraw.

What's inside

  • Checklist
  • Common RWD Problems
  • Discussion
  • Use CSS Media Queries rather than JavaScript orientationchange events
  • Use Flexible Font Units
  • Define a Fluid Grid System for layout
  • Use Flexible Margins and Padding
  • Make Images Responsive Where possible
  • Use CSS3 Media Queries
  • Accept limitations of CSS3 Media Queries

Frequently asked questions

Why should CSS media queries be used instead of JavaScript orientationchange events?

The browser reflows content before onorientationchange events reach JavaScript, so positioning in JavaScript in response to those events causes multiple repaints and hurts performance.

What body font size does the guide recommend?

It recommends setting the body font size to 100% so that ems can later be used to size the font.

How can images be made responsive?

The guide suggests using max-width of 100%, which prevents images from exceeding the width of their container, and notes it can be applied to img, embed, object and video.

What browser support does CSS Flexbox have according to the guide?

It is described as a W3C Candidate Recommendation with full support in iOS 7, BB10 and IE11, while the Android browser supports the previous syntax.

Download PDF (1.3 MB)

More IBM Manuals


View all IBM manuals →