20 November 2014

7 Principles of Rich Web Applications

Guillermo Rauch Introduces 7 actionable principles for websites that want to make use of JavaScript to control the UI.

The principles are the result of Guillermo's experience as a web developer, but also as a long-time user of the WWW.

Be sure to checkout the original article since it contains in-depth explanations and examples of the implications of the principles.

Source: 7 Principles of Rich Web Applications on rauchg.com


The principles

  1. Server rendered pages are not optional

    Server rendering is not about SEO, it’s about performance. Consider the additional roundtrips to get scripts, styles, and subsequent API requests. In the future, considering HTTP 2.0 PUSH of resources.

  2. Act immediately on user input

    JavaScript allows us to mask network latency altogether. Applying this as a design principle should even remove most spinners or “loading” messages from your applications. PJAX or TurboLinks miss out on opportunities to improve the perception of speed.

  3. React to data changes

    When data changes on the server, let the clients know without asking. This is a form of performance improvement that frees the user from manual refresh actions (F5, pull to refresh). New challenges: (re)connection management, state reconciliation.

  4. Control the data exchange with the server

    We can now fine-tune the data exchange with the server. Make sure to handle errors, retry on behalf of the user, sync data on the background and maintain offline caches.

  5. Don’t break history, enhance it

    Without the browser managing URLs and history for us, new challenges emerge. Make sure not to break expectations related to scrolling. Keep your own caches for fast feedback.

  6. Push code updates

    Pushing data without pushing code is insufficient. If your data updates automatically, so should your code. Avoid API errors and improve performance. Use stateless DOM for side-effect free repainting.

  7. Predict behavior

    Negative latency.

    Predicting user input, for example by starting to fetch data when you hover a hyperlink so that it's ready when it's clicked.

1. Server rendered pages are not optional

Server rendering is not about SEO, it’s about performance. Consider the additional roundtrips to get scripts, styles, and subsequent API requests. In the future, considering HTTP 2.0 PUSH of resources.

2. Act immediately on user input

JavaScript allows us to mask network latency altogether. Applying this as a design principle should even remove most spinners or “loading” messages from your applications. PJAX or TurboLinks miss out on opportunities to improve the perception of speed.

3. React to data changes

When data changes on the server, let the clients know without asking. This is a form of performance improvement that frees the user from manual refresh actions (F5, pull to refresh). New challenges: (re)connection management, state reconciliation.

4. Control the data exchange with the server

We can now fine-tune the data exchange with the server. Make sure to handle errors, retry on behalf of the user, sync data on the background and maintain offline caches.

5. Don’t break history, enhance it

Without the browser managing URLs and history for us, new challenges emerge. Make sure not to break expectations related to scrolling. Keep your own caches for fast feedback.

6. Push code updates

Pushing data without pushing code is insufficient. If your data updates automatically, so should your code. Avoid API errors and improve performance. Use stateless DOM for side-effect free repainting.

7. Predict behavior

Negative latency.

Predicting user input, for example by starting to fetch data when you hover a hyperlink so that it's ready when it's clicked.

Tags

  • web development
  • UX

Related collections

Don Normans Principles of Design

6 principles


Don Norman

Shneiderman's "Eight Golden Rules of Interface Design"

8 principles


Ben Shneiderman

20 Guiding Principles for Experience Design

20 principles


Whitney Hess

Design principles for reducing cognitive load

7 principles


Jon Yablonski

37 Signals Principles

8 principles


37 Signals