What it changes
Removes unreachable statements that follow unconditional control flow while retaining declarations whose hoisting can still be observed.Before and after
Configuration
Run this transform by settingtransforms.removeUnreachableCode to true:
obfuscate.mjs
View the implementation
Open the TypeScript implementation on GitHub.
Read the behavior tests
Review behavior checks and cases this transform leaves alone.