Re: Adding `detail` to Event

On Wed, Nov 28, 2012 at 12:04 PM, Olli Pettay <Olli.Pettay@helsinki.fi> wrote:

> On 11/28/2012 12:30 PM, David Håsäther wrote:
>>
>> The only reason for CustomEvent is to be able to pass a `detail`
>> object. It seems unnecessary to have a separate constructor just to be
>> able to pass an extra object, and I would suggest that Event could
>> take `detail` too (thereby deprecating CustomEvent).
>
> What is the use case for having .detail in Event?

Same use case as for having it in CustomEvent, to provide custom data.
Custom events could then use the Event constructor, instead of
CustomEvent.

--
David Håsäther

Received on Wednesday, 28 November 2012 11:13:41 UTC