Ensure that js is loaded in order