Wrap var declarations in index.html into an IIFE