I've been working on a Java app which uses Javascript to render handlebars HTML templates. I had been using Rhino in Java as the js engine, and then moved to use the Nashorn js engine.
I'd like to try using V8, via the J2V8 wrapper library. However, I need a version of env.js (which emulates various Browser/DOM functions in pure js). I had found a prebuilt env.js for rhino, and someone had built one for Nashorn, but I have not been able to find one for use with a pure V8 js interpreter.
I tried downloading the env.js github sources, it has builds for various systems like node and ruby. But I can't figure out how to build a package which is basically just a replacement for env.rhino.js that I've been using.
Had anyone built one of these, or know of something equivalent that can make V8 look similar enough to a browser that handlebars precompiled templates will run?