GiraffeQL (GFQL)
Description
GiraffeQL (GFQL for short) is a Wunder library for selecting attributes and adding attributes to models, which is commonly used to “present” data in a Rails view, for a JSON API response, or at a Service boundary.
GFQL is not intended to reshape or transform data (Ruby’s standard library is a better tool).
Technology Status at Wunder
Adopt. GFQL should be preferred over decorators, presenters, serializers, and similar approaches for most new code.
Exception to this guidance
If you need to add a small number of attributes for presentation but it’s time-consuming to list out every required attribute, then it may be pragmatic to use a decorator instead.