We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I would request a RXJS operator that is applied conditionally. For example:
public obs$ = fromEvent(document, 'someEcent').pipe( conditionalOperator(() => someLogic(), startWith(true)), )
And the operator would look kinda like this:
function conditionalOperator(predicate, pipeTrue?, pipeFalse?) { return function (source) { return source.pipe( mergeMap(value => iif(() => predicate(value), pipeTrue ? of(value).pipe(pipeTrue) : of(value), pipeFalse ? of(value).pipe(pipeFalse) : of (value))) ) } }
Would you be interested in such a operator? I would do a PR then. Is the implementation as proposed adequate?
The text was updated successfully, but these errors were encountered:
Hi, this is very specific and I don't think we should add this one. Thanks for opening the issue.
Sorry, something went wrong.
No branches or pull requests
I would request a RXJS operator that is applied conditionally. For example:
And the operator would look kinda like this:
Would you be interested in such a operator? I would do a PR then.
Is the implementation as proposed adequate?
The text was updated successfully, but these errors were encountered: