Open MarijnFK opened 4 months ago
I am not sure I understand what you want. Could you give me two code examples? One for before (the current output) and one for the output you want, both in HTML. Also what will the benefit of this be?
To make things simple I am mostly trying the match the official React plugin from Strapi.
In the output below, there is a \n in the text-property, inside a paragraph. The \n is not replaced by a
. This results in different display from the strapi-editor and the html generated from the blocks-renderer.
[
{
"type": "paragraph",
"children": [
{
"type": "text",
"text": "It would be nice to have this \n render to a <br>"
}
]
}
]
hi @MarijnFK so i found https://github.com/strapi/blocks-react-renderer/pull/42, we'll do it when it hits release.
@reslear awesome, thanks for the reply
In the strapi-blocks it is possible to input a shift-enter, which results in a \n I see there is a
option for empty paragraphs, maybe it's possible to replace line-breaks inside the 'text' property to
<br>
aswell? This way we can place<br>
inside a<p>
tag