moved create-bet JS stuff to main.js