"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.makeLoadedDataListener = makeLoadedDataListener;
exports.listenLoadedData = listenLoadedData;
function makeLoadedDataListener(listener) {
    return (component) => {
        return listenLoadedData(component, (event, _event) => {
            listener(event, _event);
        });
    };
}
function listenLoadedData(component, onLoad) {
    const { $element } = component;
    const listener = (_event) => {
        const {} = _event;
        onLoad({}, _event);
    };
    $element.addEventListener('loadeddata', listener, { passive: true });
    return () => {
        $element.removeEventListener('loadeddata', listener);
    };
}
//# sourceMappingURL=loadeddata.js.map