simple_format
with blank wrapper_tag
option returns nonsence HTML tag
#44948
Labels
simple_format
with blank wrapper_tag
option returns nonsence HTML tag
#44948
Steps to reproduce
Use
simple_format
method with blankwrapper_tag
option.Some people try to remove wrapper tag from the result of
simple_format
method, so they give an empty string towrapper_tag
option.Expected behavior
It should fallback to
p
tag:"<p></p>"
Or return no wrapper tags:
""
Or raise ArgumentError.
Actual behavior
It returns the following HTML:
"<></>"
But it is nonsense.
System configuration
Rails version: 7.0.2.3
Ruby version: 3.1.1
The text was updated successfully, but these errors were encountered: