Everything About ___
Live briefing

Everything about Tree shaking

Dead code elimination technique

In computing, tree shaking is a dead code elimination technique that is applied when bundling code with its dependencies. It is most commonly applied to dynamic languages, in practice most commonly JavaScript/ECMAScript. Often contrasted with traditional single-library dead code elimination techniques common to minifiers, tree shaking eliminates unused functions from across the bundle by starting at the entry point and only including functions that may be executed. It is succinctly described as "live code inclusion". Wikipedia →

🧭 Start here: a 6-step reading path

  1. Read the overview: Tree shakingA 5-minute orientation
  2. Skim a recent paper: Test and analysis of walnut (Juglans regia L.) tree vibration transfer based on a low-frequency shaking tableInfluential work since 2022
  3. Pick up a classic book: Masterpieces of mystery and suspenseThe most-reprinted book on the subject
  4. Read the landmark paper: Mammalian phytogeny: shaking the treeCited 486 times
  5. Go sideways: Scope (computer programming)A closely related topic
  6. Go sideways: Dead-code eliminationA closely related topic

📖 Definitions

Noun In JavaScript, automatic dead code elimination during the build.

🏆 Landmark papers (most cited)

🆕 Influential since 2022

📚 Books worth reading

Ranked by number of editions on Open Library, a rough measure of how lasting a book is.

🔗 Related topics