Code Transposition moves global code into a generated wrapper so that functions and statements no longer appear in the same straightforward structure as the original source.
How it works
The option collects global statements and functions into a generated scope, then rewrites references so the output relies more heavily on local indirection. That makes the final file harder to follow because the top-level logic is no longer exposed in a direct, readable order.
Example
Without Code Transposition:
function logit() {
}
function mylogic() {
logit();
}
With Code Transposition enabled:
var logit, mylogic;
(function () {
function a() {
}
function b() {
a();
}
logit = a;
mylogic = b;
})();
Compatibility note: test code that depends on replacing function declarations at runtime. In those cases, assigning a function to a variable can be more predictable than relying on a top-level declaration.