I saw that latest Netbeans 8.0 beta offers a way to debug JavaScript code executed in Nashorn (see attached file)
What are the steps to see this in action?
[UPDATE]
I was able to run a simple JavaScript file only by opening the file (outside any project), click inside the file, right click and then select Run File option.
I need to mention that the shortcut Shift-F6 did not worked for me.
So if anybody else knows about a different way to run this please post your solution.
[UPDATE 2]
A new article on JavaScript Nashorn mention about JavaScript debug in Netbeans
[UPDATE 3]
It seems that Nashhorn will be deprecated inside JDK. See JEP 335: Deprecate the Nashorn JavaScript Engine