Closed AlexWayfer closed 1 year ago
Not sure about this one. I added zeitwerk for convenience, to get rid of all those require
calls. And dry-types already uses it anyway, so not a big win in terms of dependencies. Actually I've never had any problems with gems based on zeitwerk.
I added zeitwerk for convenience, to get rid of all those
require
calls.
As you can see, there are not a lot of require
calls. And autoload
works good for the large list of types.
And dry-types already uses it anyway, so not a big win in terms of dependencies.
Didn't know about that. Then yes, we're loosing the point…
Actually I've never had any problems with gems based on zeitwerk.
I feel uncomfortable when see third-party gems in exception call stack, especially for core features like require
. But yeah, there are no problems (for now).
OK, since dry-types
uses it, let's close this.
Firstly I've replaced it with
require_relative
,Dir[].each { require }
, and littleautoload
(to resolve circular dependency).Then I've decided to use
autoload
for everything.What do you think?