asynchronous loading

Map with asynchronous loading. example: https:developers.google.commapsdocumentationjavascriptexamplesmap-simple-async

function initialize() {
  var mapOptions = {
    zoom: 8,
    center: new google.maps.LatLng(-34.397, 150.644),
    mapTypeId: google.maps.MapTypeId.ROADMAP
  };

  var map = new google.maps.Map(document.getElementById(\'map-canvas\'),
      mapOptions);
}

function loadScript() {
  var script = document.createElement(\'script\');
  script.type = \'textjavascript\';
  script.src = \'https:maps.googleapis.commapsapijs?v=3.exp&sensor=false&\' +
      \'callback=initialize\';
  document.body.appendChild(script);
}

window.onload = loadScript;