Kwargs conversion of many methods
Summary
Convert many methods and calls to use keyword arguments instead of hashes.
Methods which take a Configuration haven't been converted, such as Bridgetown::Site.new, or initializers of the Converter classes. I started to attempt this but then ran into difficulty, particularly with the converters. I think it's related to Configuration being a HashWithDotAccess::Hash. I didn't want to go too deep down the rabbit hole, especially as there's a comment suggesting the config may be refactored at some point.
Context
Supports resolving of #581
Very cool @vvveebs, I appreciate your attention to detail! I should have time to review this after getting the first beta of v1.2 out the door.
I've got into a tangle with failing ruby 3 tests. I'll promote this draft PR to ready to review if I can resolve these.
I think we can punt on this and reevaluate for v1.3 or whatever…at this point I don't want to introduce any more major changes before the 1.2 release.
Thanks @neilvanbeinum for working on this. I believe there are a number of places where we wouldn't want to make this change, particularly models and anything interfacing with Roda. I may want to back out of this for the time being and review such changes on a case-by-case basis.
I agree with @jaredcwhite here.
I think keyword arguments is the way to go for new methods, but I wouldn't introduce them like this.
**options is mostly an anti-pattern. For internal APIs, one can convert from options to real keyword arguments when working on that specific code.
For public APIs, I'd do it full on, i.e. explicitly say which kwargs we are expecting for each method, and then treat it as a breaking change (since it's a public API).