I am using SQLBoiler to generate my models and I am using the JSONB data type for one of my database fields, which translate over to
types.JSON in Go with
types being a package from SQLBoiler. What’s is the best way to marshal and unmarshal this type? Should I just have a resolver for that specific field or should I create a custom scalar for it? Though I don’t think I can create a custom scalar because it seems like I would need to create new methods for a struct in another package.