UNPKG

@opra/core

Version:
24 lines (23 loc) 804 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.PlatformAdapter = void 0; require("./augmentation/18n.augmentation.js"); const common_1 = require("@opra/common"); const node_events_async_1 = require("node-events-async"); const asset_cache_js_1 = require("./asset-cache.js"); const constants_js_1 = require("./constants.js"); /** * @class PlatformAdapter */ class PlatformAdapter extends node_events_async_1.AsyncEventEmitter { constructor(options) { super(); this[constants_js_1.kAssetCache] = new asset_cache_js_1.AssetCache(); this.i18n = options?.i18n || common_1.I18n.defaultInstance; this.logger = options?.logger; } get document() { return this._document; } } exports.PlatformAdapter = PlatformAdapter;