AppInit.appReady(function () {
     webfont.init()
         .done(init) // only register commands if the core loaded properly
         .fail(function (err) {
             // TODO: Should probably keep trying at some interval -- may have failed because not connected to net
             console.log("[edge-web-font extension] failed to initialize: " + err);
         });
 });
 (function startExtensionHelper() {
     webfont.init()
         .done(function () {
             init(); // register commands if the core loaded properly
             if (window.navigator.onLine) {
                 handleOnline();
             } else {
                 window.addEventListener("online", handleOnline);
             }
         }).fail(function (err) {
             if (window.navigator.onLine) {
                 setTimeout(startExtensionHelper, delay);
                 if (delay < MAX_DELAY) {
                     delay *= 2;
                 }
             } else {
                 window.addEventListener("online", startExtension);
             }
         });
 }());