JimLiu / bbcode-to-react

A utility for turning raw BBCode into React elements.
MIT License
24 stars 21 forks source link

New Lines / Line Breaks are not correctly rendered #2

Closed vladislavsuljanovs closed 7 years ago

vladislavsuljanovs commented 7 years ago

Hey guys, not sure what I'm doing wrong but the parser doesn't output new lines / line breaks using toReact method. toHTML method works well but then I have a problem with Quotes :(.

render() { return <div className="html-content"> {parser.toReact(this.props.toParse)} </div> }

I believe that the space / newline exists under this form:

screen shot 2017-07-08 at 14 14 09

Which is enter/return key symbol. How do we add this to the module ?