Sorbet sig conflict with ViewComponent collection rendering
Published Nov 11, 2020
Error message:
FooComponent initializer must accept `foo` collection parameter.
Solutions that didn’t work:
-
::Method.prepend(T::CompatibilityPatches::MethodExtensions)
The methods we’re looking at turn out to be
::UnboundMethod
instances. -
::UnboundMethod.prepend(T::CompatibilityPatches::MethodExtensions)
Infinite recursion somehow!
Solution that did work:
|
|
I’ll definitely be cleaning this up and writing a real blog post about it. This deserves a real explanation but I have to find one first!