Generate a JS file rather than an entire HTML file