A page that works is a good start, but a page that loads quickly and is written cleanly is better. Visitors leave slow pages, and messy markup is harder to fix, share and build on. The habits in this module are small, and most of them are a single attribute or a single decision, but together they make a real difference.
This module starts with lazy loading, so images below the fold don't slow down the first view of the page. It then covers responsive images, which let each device download an image that suits its screen. Next you'll learn how async and defer change the way scripts load, and it finishes with HTML best practices for writing semantic, readable and accessible markup.
Watch the lessons in order, then put everything together in the Projects.
Shows how the loading attribute lets browsers lazy load images, so you save bandwidth and improve the speed of your site.
Explains how responsive images work in HTML with srcset, so images stay sharp on any screen without wasted downloads.
Looks at the async and defer attributes of the script tag and the difference between them when including JavaScript in HTML.
A beginner guide to HTML best practices, with a focus on writing semantic and accessible code.