-
Notifications
You must be signed in to change notification settings - Fork 24.8k
New issue
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
docs: square odds example in rxjs guide #24947
Conversation
Did you test it? It works correctly, because |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The git commit message should be updated to docs: square odds example in rxjs guide
@@ -8,7 +8,7 @@ const nums = of(1, 2, 3, 4, 5); | |||
|
|||
// Create a function that accepts an Observable. | |||
const squareOddVals = pipe( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be updated to add a type to the n
value in the filter
function. See #24560 for context.
@palerdot squash these down to a single commit with the updated message. |
Added argument type to filter function of rxjs. Fixed the return value of filtering of odd numbers
@brandonroberts squashed into a single commit |
Added argument type to filter function of rxjs. Fixed the return value of filtering of odd numbers PR Close #24947
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
The example
squareOdd
for showing squaring odd numbers using RxJS operators is wrong. The current snippet will square even numbers. The same example is shown correctly in thechaining
section.PR Checklist
Please check if your PR fulfills the following requirements:
PR Type
What kind of change does this PR introduce?
What is the current behavior?
Issue Number: N/A
What is the new behavior?
Does this PR introduce a breaking change?
Other information