As with all programming languages, the choice really boils down to what you're prepared for and what you are doing to create your resources. JS is still very much a web technology, whereas Java is a general-purpose programming language that can create anything