Why does lightning-input-rich-text add a paragraph tag automatically to the text?
I am using a LWC lightning-input-rich-text that is populated from a custom field value when my LWC loads. This component is used to Send an email where body of email will be the text(
value ) in this input rich text. When I send the email I get additional paragraph for each line break present in the text. Could not find this behavior anywhere in documentation, this one says that
<p> tag is added for text enclosed in
<p> tags , but my rich text does not have any of this, and this behavior is observed wherever there is a line break.
Is this a bug? Is there any workaround for this? I tried replacing all
</p> tags with blanks but this will also remove the required
tags that were explicitly added in rich text originally.