Skip to content

Instantly share code, notes, and snippets.

@Chester97
Created April 28, 2021 15:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Chester97/39b491b3ab773eb0a5f14e7d4c85b3ef to your computer and use it in GitHub Desktop.
Save Chester97/39b491b3ab773eb0a5f14e7d4c85b3ef to your computer and use it in GitHub Desktop.
scrollObservable.pipe(
mergeMap(value => {
const { currentPosition, maxPosition } = value;
console.log("VAL: ", value);
if(currentPosition >= maxPosition) {
return getPokemon$(10).pipe(
map(value2 => console.log("VAL2: ", value2))
)
}
})
).subscribe(data => console.log(data));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment