import { operate } from "../util/lift.mjs";
import { createOperatorSubscriber } from "./OperatorSubscriber.mjs";

//#region ../../node_modules/.pnpm/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/operators/filter.js
function filter(predicate, thisArg) {
	return operate(function(source, subscriber) {
		var index = 0;
		source.subscribe(createOperatorSubscriber(subscriber, function(value) {
			return predicate.call(thisArg, value, index++) && subscriber.next(value);
		}));
	});
}

//#endregion
export { filter };
//# sourceMappingURL=filter.mjs.map