thenativeweb / node-cqrs-eventdenormalizer

Node-cqrs-eventdenormalizer is a node.js module that implements the cqrs pattern. It can be very useful as eventdenormalizer component if you work with (d)ddd, cqrs, domain, host, etc.
http://cqrs.js.org/pages/eventdenormalizer.html
MIT License
38 stars 27 forks source link

How to use 'meta' in `defineViewBuilder` #69

Closed alemhnan closed 6 years ago

alemhnan commented 6 years ago

I can set the 'meta' field in the `defineEvent' and I would like to subsequently use that value in a viewBuilder.

Is there a way to achieve that? The function being passed as only 'data', the viewModel and eventully the callback.

If I do not define explicitly the payload field I do get the whole event with the sub fields 'data' and 'meta' but it would be nice to access the 'meta' field directly.

adrai commented 6 years ago

not possible... you need to handle the whole event