Add custom JSON serializer for Observable objects.