Firefox and Chrome would claim they prefer a html or xml document when doing the request for the page, like this (from Chrome):
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
and text/css for <link rel="stylesheet" type="text/css">, like:
Accept: text/css,*/*;q=0.1
But when it comes to <script src>, it becomes
Accept: */*
without claiming application/javascript despite it will accept only javascript.
Why would it behave like that ?
It reduces the size of the Accept header and thus saves some bandwidth leading to a performance boost.
See bug 170789
Also, it helps to minimize errors on sites expecting headers of fixed maximum length.