djlint was re-formatting the HTML to put the label element on separate lines. However, this caused there to be whitespace surrounding the text for the field label.
This PR disables djlint for the form's label elements and removes the whitespace. See djlint docs on ignoring code.
The built-in spaceless tag from Django was close to what we needed except that it doesn't remove whitespace between tags and text.
Fixes #2033
djlint was re-formatting the HTML to put the
label
element on separate lines. However, this caused there to be whitespace surrounding the text for the field label.This PR disables djlint for the form's
label
elements and removes the whitespace. See djlint docs on ignoring code.The built-in
spaceless
tag from Django was close to what we needed except that it doesn't remove whitespace between tags and text.