add generate.js for static test