选择Symfony表单视图中的所有复选框

In symfony form I have some choices, checkboxes.

$form->add('keywords', ChoiceType::class, array(
            'choices' => $keywords,
            'label' => 'With following keywords',
            'expanded' => true,
            'multiple' => true,
        ));

I need all checboxes selected when form is initialised. How I can do that if possible in symfony way or I will need to do that with JavaScript?

Just add choice_attr

$form->add('keywords', ChoiceType::class, array(
            'choices' => $keywords,
            'label' => 'With following keywords',
            'expanded' => true,
            'multiple' => true,
            'choice_attr' => function() {
                return ['checked' => 'checked'];
            },
        ));