You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Would you accept a patch to update the BaseNodeRenderer#find_renderer method to not just blindly instantiate a class, but instead If the renderer responds to #call, call that with the mappings & node. This allows for whoever is doing the renderer to pass their own lambdas or instantiated objects in with more state.
My particular use case is for rendering referenced entries. Having more configurable renderers that I can instantiate on my own means I can pass along a reference of all the referenced entries and continue rendering recursively.
I appreciate this will change the method signature to pass the mappings along with the node to #render, and there should be a backwards compatible way to do this
The text was updated successfully, but these errors were encountered:
Would you accept a patch to update the
BaseNodeRenderer#find_renderer
method to not just blindly instantiate a class, but instead If the renderer responds to#call
, call that with the mappings & node. This allows for whoever is doing the renderer to pass their own lambdas or instantiated objects in with more state.My particular use case is for rendering referenced entries. Having more configurable renderers that I can instantiate on my own means I can pass along a reference of all the referenced entries and continue rendering recursively.
I appreciate this will change the method signature to pass the mappings along with the node to
#render
, and there should be a backwards compatible way to do thisThe text was updated successfully, but these errors were encountered: