One can just as easily say, "If you were using CoffeeScript this nonsense could have been avoided" :-)
Adding a semicolon to the start of your IIFE doesn't really hurt, but it's a workaround more than a solution.
These are conventions, not because you have to, but because you avoid other issues further down. You COULD simply write all your scripts inline.. and if you are judicious it is probably a bit better performing. That doesn't mean you want to... JavaScript in practice is much more about convention to prevent/limit obstacles than a "one right way" philosophy.
Hell, look at CommonJS vs AMD and the various solutions there alone... not even including all the one-off processes that have been used over the years.
I think I picked this example in a bootless attempt to humblebrag by pointing out something I'd been cargo culting.