For the JS file types, please refer to the snippet below.
You may add and block the js file types by utilizing the search feature as shown in the snippet below. You may choose to not go with the "Default".
Having simulated this within our lab environment, we have the below results.
Even though it looks like there's a download, the scripts aren't actually downloaded, in the real sense of it. The files won't open and not usable. Please see the snippets below.
Please see how the implementation was set up within our lab, below.