4.6 - Using new GUI with JavaScript functions

Hi Guys, I’m trying to use the new GUI system with 4.6 with a Javascript function. Only examples I can find online are C#

Is it even possible?

41724-screen-shot-2015-03-03-at-203620.png

It works just fine with JavaScript, just make sure your functions are marked as public and they should show up in that box.