geo4.js 252 B

12345678910111213
  1. require(["Geo", "MessageElement"], function () {
  2. "use strict";
  3. var geo = new Geo();
  4. var area = new MessageElement("geo");
  5. if (geo.getGeo()) {
  6. geo.showLocation(area);
  7. }
  8. else {
  9. area.set("Geolocation API is not available.");
  10. }
  11. });