DZone

Lazy loading is a common technique to improve performance in web applications. The concept is simple—instead of loading everything upfront, leading to the annoying “loading” message experienced by many users of single page applications—the application loads components only when they are actually requested or needed by the user. 

Lazy loading is supported natively in many web development frameworks. In this article, I discuss the concept of lazy loading and how to implement it in pure JavaScript, and using built-in functionality in Angular and React. Finally, I provide a quick tutorial showing a real life implementation of lazy loading in a single page application.

Source: DZone