Joshfire not defined because of the script tag order in index.html