"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Subscriber = void 0;
var tslib_1 = require("tslib");
var React = tslib_1.__importStar(require("react"));
var context_1 = require("../components/map-providers/context");
/**
 *
 * @param props
 * @since 0.13
 */
var Subscriber = function (props) {
    var state = (0, context_1.useAppState)(props.appStateSelector, props.appStateEqualityFn);
    React.useEffect(function () {
        props.onNewState(state);
    }, [state]);
    return React.createElement("noscript", { "data-subscriber-name": props.name });
};
exports.Subscriber = Subscriber;
//# sourceMappingURL=subscriber.js.map