I have some simple boolean field and I want to add a short description.
I specified a description
parameter but it seems like no effecr.
How it suppose to work at all?
from wtforms import BooleanField, Form
class AdminUsersForm(Form):
foo = BooleanField(label='foo', default=True, description='foo')
<form method="GET">
<div>
{{ form.foo.label }}
{{ form.foo(placeholder=checkbox.description)}}
# No description impact at all, even tooltip.
</div>
</form>
I found this answer but not sure that it's my case
You almost have it. Try changing your 'placeholder' to display the text that you have defined:
You access this the same way as the
form.label
, simply by calling the parameter of the field of the form.