Moving startup code to startup.js
Some documentation