Instead of only allowing the registration and use of callable (i.e. function) to do the serialisation/deserialisation for a given type, let's allow them to register a class made for this.
Some people might already have one of those made to use with the basic json package right now.
Little note here though: I'd prefer if this lib did not relly specifically on the json package. It does right now, but this feature might cause some hard-coupling with the json package and it's implementation. Allowing the use of classes overall might be a better idea. I could split the case if it's JSONEncoder/JSONDecoder subclasses and if they're not?