awesome-cordova-plugins/dist/index.js

26 lines
1.1 KiB
JavaScript
Raw Normal View History

2015-11-26 01:44:58 +08:00
function __export(m) {
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
}
2015-11-30 06:30:15 +08:00
var DEVICE_READY_TIMEOUT = 2000;
2015-11-30 11:55:18 +08:00
__export(require('./plugins/actionsheet'));
2015-12-01 01:09:50 +08:00
__export(require('./plugins/ble'));
2015-11-30 11:55:18 +08:00
__export(require('./plugins/camera'));
2015-12-01 12:15:21 +08:00
__export(require('./plugins/calendar'));
2015-12-01 01:09:50 +08:00
__export(require('./plugins/contacts'));
2015-11-30 11:55:18 +08:00
__export(require('./plugins/device'));
2015-12-01 10:17:55 +08:00
__export(require('./plugins/facebook'));
2015-12-01 02:34:54 +08:00
__export(require('./plugins/geolocation'));
2015-11-30 11:55:18 +08:00
__export(require('./plugins/statusbar'));
2015-11-29 06:24:38 +08:00
__export(require('./plugins/toast'));
2015-12-01 03:27:25 +08:00
var before = +new Date;
2015-11-30 06:30:15 +08:00
var didFireReady = false;
2015-12-01 03:27:25 +08:00
document.addEventListener('deviceready', function () {
console.log('DEVICE READY FIRED AFTER', (+new Date - before), 'ms');
2015-11-30 06:30:15 +08:00
didFireReady = true;
});
setTimeout(function () {
2015-11-30 07:20:11 +08:00
if (!didFireReady && window.cordova) {
2015-11-30 06:30:15 +08:00
console.warn('Native: deviceready did not fire within ' + DEVICE_READY_TIMEOUT + 'ms. This can happen when plugins are in an inconsistent state. Try removing plugins from plugins/ and reinstalling them.');
}
}, DEVICE_READY_TIMEOUT);
2015-12-01 02:34:54 +08:00
//# sourceMappingURL=index.js.map