trailblazer / trailblazer.github.io

The TRAILBLAZER.TO website. Please PR against the f6 branch. 💋
http://trailblazer.to
23 stars 55 forks source link

Fix and improve operation contract dependency injection automation documentation #45

Closed ZimbiX closed 8 years ago

ZimbiX commented 8 years ago

The result of discussions with @fran-worley on Gitter =)

seuros commented 8 years ago

Thank you @ZimbiX

ZimbiX commented 8 years ago

No problem. I'm glad I could help

fran-worley commented 8 years ago

Can we make sure that we've got the args correct. I think it was correct before

See this warning: https://github.com/apotonick/trailblazer/blob/master/lib/trailblazer/operation.rb#L180-L182

@ZimbiX I'm not sure quite why you only had 2 args coming through but everything I can see in the source (certainly on master) points to the three args.

ZimbiX commented 8 years ago

Hmm. Are we documenting the bleeding edge, or the latest release?

I see that in the current release, v1.1.1, the args are as I had it: https://github.com/apotonick/trailblazer/blob/1bc467ba13223f74429e01aff6501ae499c1a9ca/lib/trailblazer/operation.rb#L161

Should we add the examples for both? Or update the arguments, note the signature change, and show what it was pre- v1.2.0?

fran-worley commented 8 years ago

I'm going to suggest we put this to @apotonick...

ZimbiX commented 8 years ago

Actually, what about adding a new method for dependency injection?