Wrote setup function. BSing in javascript.