Closed Phoscur closed 1 month ago
Ummmmm let me check on that. It definitely should forward those on. Should be a pretty small fix if you want to take a look at the injectable decorator.
https://github.com/joist-framework/joist/blob/main/packages/di/src/lib/injectable.ts#L18
Yes just found that, shall I submit a fix with a test?
Yes just found that, shall I submit a fix with a test?
Please do! Will be happy to review :)
Nice, when can I expect new versions? @deebloo
Sidenote concerning unit tests:
Why the switch from expect
to assert
, while chai actually supports both?
Sometimes today. Right now it's time for football :). And no real reason. I prefer assert and it is also the format that the native node assert module uses.
@Phoscur new releases cut for both 4.0 and 3.0
Nice, I'm on 3.9.2 now and it's fixed! Should I consider upgrading to v4 asap?
Up to you. The di package is really stable. No more changes unless bugs are found.
Describe the bug Maybe this should be a feature request, I have probably overlooked a hint in the docs...
To Reproduce, run:
Expected behavior Should print 'b' - forwarding the argument to the orignal constructor Prints 'a' instead (both v3 & v4.next11)
Additional context I found hints for constructor usage near the docs for provider factory usage. It would be helpful to be able to also use different constructor arguments for decorated services!