I was going to use Notepad but then realized that one of the free/open source editors might be a bit better. Searched the Forum and didn't see any recommendations or other questions.
I use Notepad++
It does not know much about c# or js libraries, but it's good enough general script/code source editor with syntax highlight and common source code editing features.
Visual Studio 2013 community edition has lots of tools for javascript support (from codeplex) and it's free. As the other author said, it javascript, not java.