added code to generate a version.js file in public path