Fixed main.js in the example