Isn't this a tooling issue, namely using something like Google's Closure Compiler to perform dead-code elimination?
https://developers.google.com/closure/compiler/docs/api-tuto...
https://developers.google.com/closure/compiler/docs/api-tuto...
tldr: The reason people pull it as an extern is because it does not work with advanced optimisations.