✊🏿 Black Lives Matter. Please consider donating to Black Girls Code today.
⚡️ Concerned about the grid? Kyle Baranko teaches how to predicting peak loads using XGBoost. Register for the August webinar!

How can i add new lines in dbc.ModalBody('Text in first line \n Text in second line')

How can i add new lines in dbc.ModalBody(‘Text in first line \n Text in second line’)

The result in the modal should be:

Text in first line
Text in second line

Please help me out. Thanks in advance.

hi, i write sample code.


dbc.Modal(
[
dbc.ModalHeader(…),
dbc.ModalBody([
html.Div(“Text in first line”),
html.Div(“Text in second line”),
]),
dbc.ModalFooter(…),
],
id=“hogehoge”,
)

Thanks alot :slight_smile: for this simple hack