Created
April 21, 2024 11:07
-
-
Save rbaul/4b4f863b1128844f27c31ade989c12d7 to your computer and use it in GitHub Desktop.
React flux demo doOnNext and count
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ReactDemo { | |
public static void main(String[] args) { | |
Flux.range(1,0) | |
.doOnNext(System.out::println) | |
.count().doOnNext(size -> { | |
if (size == 0) { | |
System.out.println("Size is: " + size); | |
} | |
}).subscribe(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment