Answer the question
In order to leave comments, you need to log in
Why is the OptionsResolverInterface interface deprecated in the Symfony Form component?
I noticed a long time ago that the OptionsResolverInterface interface in the Form component is marked as deprecated. But even in the official documentation , it is used when creating a form class:
use Symfony\Component\OptionsResolver\OptionsResolverInterface;
public function setDefaultOptions(OptionsResolverInterface $resolver)
{
$resolver->setDefaults(array(
'data_class' => 'AppBundle\Entity\Task',
));
}
@deprecated Deprecated since Symfony 2.6, to be removed in Symfony 3.0.
Use {@link OptionsResolver} instead.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question