4 ms·
undefined couldn't be minified. If you assigned it to an undefined variable early on, any minifier could easily convert it to yet another single-character varia
by ttfkam 3y ago
undefined couldn't be minified. If you assigned it to an undefined variable early on, any minifier could easily convert it to yet another single-character variable name.
undefined became U (for example). An 8-byte or more reduction per reference. What can I say? Size used to matter. (Been doing JS since 1996.)
- no_wizard 3y agoIf you allow it I think most minifiers nowadays use `void 0` for undefined as it’s smaller. Though I should try this, using a variable alias for undefined and null would maximize minification.