thenativeweb / node-cqrs-domain

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

Support of default export? #101

Open IRT-fbachmann opened 7 years ago

IRT-fbachmann commented 7 years ago

Could you add support of default exports in the structureLoader? Sth. like this:

if (required.default) {
    required = required.default;
}
adrai commented 7 years ago

Feel free to submit a PR ;-) PS. but there is no official support in node right now, right?

IRT-fbachmann commented 7 years ago

No, there is no official node support. However, in my structure I liked to have some supporting information associated to the commands/events. I'd like to have that in the same file, which is easier using default export plus extra exports... PR's coming :)