deviantintegral/jms-serializer-uri-handler

A handler for serializing and deserializing PSR-7 URI objects

1.2.0 2022-08-10 11:50 UTC

This package is auto-updated.

Last update: 2024-11-27 11:40:44 UTC


README

CircleCI

This library supports serializing and deserializing URI instances, as defined by PSR-7.

Add this handler to your serializer with the following:

AnnotationRegistry::registerLoader('class_exists');
$this->serializer = SerializerBuilder::create()
  ->configureHandlers(
    function (HandlerRegistry $registry) {
        $registry->registerSubscribingHandler(new UriHandler());
    }
  )->build();