Support option handlers in JS

Signed-off-by: Joern Bernhardt <jb@campudus.com>
Use toJson() and convert to js object

Signed-off-by: Joern Bernhardt <jb@campudus.com>
Merge pull request #9 from vert-x3/support-option-handlers

Support option handlers in JS