UNPKG

@skippay/capacitor-localization-settings

Version:

Capacitor module to expose per-app language preferences API on iOS and Android.

27 lines (20 loc) 719 B
'use strict'; Object.defineProperty(exports, '__esModule', { value: true }); var core = require('@capacitor/core'); const LocalizationSettings = core.registerPlugin('LocalizationSettings', { web: () => Promise.resolve().then(function () { return web; }).then(m => new m.LocalizationSettingsWeb()), }); class LocalizationSettingsWeb extends core.WebPlugin { async getLanguage() { return { value: navigator.language }; } async setLanguage(options) { return options; } } var web = /*#__PURE__*/Object.freeze({ __proto__: null, LocalizationSettingsWeb: LocalizationSettingsWeb }); exports.LocalizationSettings = LocalizationSettings; //# sourceMappingURL=plugin.cjs.js.map