Php – How to create initial Object with Symfony serialization
For example I have SimpleDto class class SimpleDto implements GetPhoneInterface { public string $name; public int $value; } And json {"name":"Jane"} When I serialize it, i get not valid object. $serializer = self::getContainer()->get(SerializerInterface::class); $dto = $serializer->deserialize($json, $dtoClass); $dto has not…