This borrows some logic from the serializer resolution logic in active_model_serializers. Given that active_model_serializers no longer supports the namespace option passed into the serializer_for method, in order to support namespace inference we need to reuse some of their serializer_for logic in grape-asm. I will work with the asm team to add back support for that option, but in order to support the existing 0.10.x asm versions, we need to reimplement some of that logic.
This reimplements the changes in pull https://github.com/ruby-grape/grape-active_model_serializers/pull/58 on top of the refactor of pull https://github.com/ruby-grape/grape-active_model_serializers/pull/59.
This borrows some logic from the serializer resolution logic in active_model_serializers. Given that active_model_serializers no longer supports the
namespace
option passed into theserializer_for
method, in order to support namespace inference we need to reuse some of theirserializer_for
logic in grape-asm. I will work with the asm team to add back support for that option, but in order to support the existing 0.10.x asm versions, we need to reimplement some of that logic.