Closed HelloGrayson closed 7 years ago
Definitely. Shouldn't be hard to do, there are examples of that in the dig repo, such as traverseOutTypes
Do we want to explode one per line, or keep things combined:
[Fx] PROVIDE zap.AtomicLevel, *zap.Logger, *zap.SugaredLogger <= vendor/code.uber.internal/go/zapfx.git.module()
Exploded - log lines should be line-oriented, and I want people to be able to easily scan down the column to explore what types are available.
In order to properly implement this fxlog
packages needs to know what is and what isn't In/Out objects. It's fairly trivial to duplicate that logic, but I don't think that's the best approach in the long term.
I think the right thing to do is to export the currently private isInObject
and isOutObject
dig functions: https://github.com/uber-go/dig/blob/master/types.go#L69
Suggest just calling it IsOut
and IsIn
Resolved in #126
When Fx's output encounters a
dig.Out
, it should print a log line for each dependency being provided in thedig.Out
.So instead of:
It should contain: