Thing is, you can't load javascript code... But you can easily write a mini virtual machine to run any code you download from the web. And due to javascripts introspection abilities, that VM can (if the developer wishes) do anything.
The simplest javascript bytecode interpreter is probably only a few hundred bytes, which is easy to hide in a big extension.
The simplest javascript bytecode interpreter is probably only a few hundred bytes, which is easy to hide in a big extension.