네트워크 요청, 이미지 처리, 파일 디코딩 과 같은 연산자원을 공유하고 싶을 때

구독 때마다 네트워크 요청을 발생시키지 않고, 하나의 요청 결과를 공유하고 싶을 때

share() → 이 친구 RxSwift share() 랑 동작이 좀 다름

multicast(_:)

🔑 Key points


The share() operator


<aside> 💡 Rx 의 share() 와 다르다.

헷갈리지 말자!!

share(replay:scope:)

</aside>

“shares” the upstream publisher

The purpose of this operator is to let you obtain a publisher by reference rather than by value.