What is Tree Shaking?
Automatically removing unused code from your final bundle to make it smaller.
Why It Matters
Tree shaking reduces the amount of JavaScript sent to browsers, making your site load faster.
Real-World Example
If you import only one function from a large library, tree shaking removes all the unused functions from your bundle.
“Understanding terms like Tree Shaking matters because it helps you have better conversations with developers and make smarter decisions about your software. You do not need to be technical. You just need to know enough to ask the right questions.”
Related Terms
Bundler
A tool that combines your many source files into optimised bundles that browsers can load efficiently.
Code Splitting
Breaking your application's code into smaller chunks that load only when needed.
Bundle
Combining multiple files into fewer files for more efficient loading
Build
The process of converting your source code into the optimised version that runs in production
Learn More at buildDay Melbourne
Want to understand these concepts hands-on? Join our one-day workshop and build a real web application from scratch.
Related Terms
Build
The process of converting your source code into the optimised version that runs in production
Bundle
Combining multiple files into fewer files for more efficient loading
Bundler
A tool that combines your many source files into optimised bundles that browsers can load efficiently.
Code Splitting
Breaking your application's code into smaller chunks that load only when needed.
Cache
A temporary storage that keeps copies of frequently accessed data for faster retrieval
CDN
A network of servers around the world that stores copies of your content closer to users