First draft of main.js