yes java script is not that safe, it can download virus on your client systems. hence they should not be used if you can use some alternative ones.