This is just src/util/url.js wrapped in an IIFE instead of module. resolveUrl is required by registerModule so it needs to be available before we have module infrastructure in place.