I'm not sure that these guidelines make a distinction between a call to install a codec on-demand versus a call to download and run (and even cache) a minified Javascript library.
The difference is whether the user has explicitly asked for it. If I point my web browser at a url, I am instructing it to download and execute whatever it finds there. However, if the browser decides to download a codec on-demand, it is making an executive decision as to what code should run on the machine - and to select non-free code without user interaction is a violation of trust.
An analogous situation would be the non-free NVidia blob. Debian fully supports installing it, but it would be very much verboten to do so by default, automatically.
> If I point my web browser at a url, I am instructing it to download and execute whatever it finds there.
And your browser will download linked javascript from third party websites to make it run. As firefox downloads a codec from a third party to make the media you've requested run.
I actually agree about the conflict between this codec behavior and the Debian philosophy. But they need to come to terms with the much greater conflict with their philosophy that the modern internet experience presents.
Stallman, for all his faults, was right about a lot of things. We live in a world where people don't own their own books, and buy software on a subscription model. For a few years back in the late 90s and early 2000s it looked like free software was the answer. But the internet made an end run around it, and Debian, etc., hasn't caught up. We're all digital renters instead of owners.