Question · JavaScript and TypeScript course · Module 9: Design Patterns and Architecture

Tree Shaking

What is tree shaking in the context of JavaScript bundling?

Answer options

  • Sorting project files by directory tree structure
  • An image compression technique in web applications
  • A method of testing applications with random input data
  • Automatically removing unused code (dead code) from the final bundle

You can check the correct answer by solving this task in the CodeWorlds game.