K
K
KOPC18862016-09-23 14:45:15
css
KOPC1886, 2016-09-23 14:45:15

How to move part of a string to a new line in a component property?

How to move part of a string to a new line in a component property?
<Component text={"Hello <br> world"}/>
So it displays "Hello br world" as text.
How can I make it
move to a new line?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
K
KOPC1886, 2016-09-23
@KOPC1886

Did so.
<Component text={<span>Hello <br/> world</span>}/>

M
Maxim, 2016-09-23
@maxfarseer

Perhaps it will help dangerouslySetInnerHTML
An example of usage is in the tutorial (search on the "rawMarkup" page)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question