As I told you, this is not the first time Google has blocked such files. Before also Gmail has blocked use of certain file types that include .exe, .msc, and .bat. So from January 13 if you try to send a .js file attachment, then you will be prompted with an in-product warning with block on the file and explaining why it’s blocking this file.
The warning massage will read “There are a number of reasons why you may see the ‘This message was blocked because its content presents a potential security issue’ error in Gmail. Gmail blocks messages that may spread viruses like messages that include executables files or certain links.”
However, Google has kept alterations to send such files and you can make of use the Google Drive, Google Cloud Storage, or other storage solutions to send or share the .js files. As Google states, it even blocks certain compressed file forms such as .gz or .bz2 as those too are prone to security attacks. Google too blocks the archive listed files which content is password protected or whose content includes a password protected archive. This is a measure to prevent the hackers from stealing personal information and data using the .js attachments.
Also Read: Google Voice on the way to a big revamp