title: Adding Attribute to crispy forms django
body: <p>I am using bootstrap switch and it looks like if I want to add a label I need to:</p>
  <pre><code>&lt;input name=&quot;switch-labelText&quot; type=&quot;checkbox&quot; data-label-text=&quot;Label&quot;&gt;
  </code></pre>
  <p>I am using crispy forms and I can see that I can do add attribute using the Field like so:</p>
  <pre><code>Field('field_name', css_class=&quot;black-fields&quot;)
  </code></pre>
  <p>This all makes sense to me but I can't seem to add data-label-text. So my question is can I make a custom attribute with crispy forms?</p>
  <p>Here is my form:</p>
  <pre><code>class InstanceCreationForm(forms.Form):
      some_field = forms.BooleanField(required=False)
      some_field2 = forms.BooleanField(required=False)
      some_field3 = forms.BooleanField(required=False)
  
      def __init__(self, *args, **kwargs):
          super(InstanceCreationForm, self).__init__(*args, **kwargs)
          self.helper = FormHelper()
          self.helper.form_show_labels = False
          self.helper.layout = Layout(
              #This is a syntax error
              Field('some_field', data-label-text=&quot;whatever&quot;)
          )
          self.helper.add_input(Submit('submit', 'Submit'))
  </code></pre>