respond-framework
Version:
create as fast you think
16 lines (15 loc) • 468 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
const changePath = (state, e) => {
if (e.meta.parallel && e.meta.changePath !== true) return;
if (e.event.changePath) {
const other = e.event.changePath.call(state, state, e);
other && state.respond.history.changePath(other);
} else if (e.event.pattern) {
state.respond.history.changePath(e);
}
};
var _default = exports.default = changePath;