How can I add attributes to a nested field PasswordType
(attribute always_empty
)? This code doesn't work:
$builder
->add('password', RepeatedType::class, [
'type' => PasswordType::class, [
'always_empty' => false
],
'first_options' => ['label' => 'Password'],
'second_options' => ['label' => 'Repeat Password'],
])
;