May 09, 2021

On Sunday, 9 May 2021 at 11:11:35 UTC, Bastiaan Veelo wrote:

>

For someone alien to React, how would you describe the main differences?

It is more like a protocol than an implementation, so that you can implement it in many different ways depending on the datastructure you want to observe. Fits well with RAII. IIRC, the key point is that you obtain a subscriber-delegate that produces an unsubscribe delegate when you subscribe. You then call it from the destructor of the observer-owner.

I assume you can use it for wrapping existing C/C++ libraries. What is convenient is that you can change the implementation without changing the entire codebase.

May 09, 2021

On Sunday, 9 May 2021 at 11:20:53 UTC, Ola Fosheim Grøstad wrote:

>

On Sunday, 9 May 2021 at 11:11:35 UTC, Bastiaan Veelo wrote:

>

For someone alien to React, how would you describe the main differences?

It is more like a protocol than an implementation, so that you

I guess I should mention that the advantage of this would be that you can write code for the protocol. Working kinda like ranges with filter(), map() etc, so that the observer gets conveniently filtered and converted data using ranges-like library functions.

1 2
Next ›   Last »