Simplify generation of browser JavaScript