I\'m creating a note app where users can add a note by entering multiline text in a textarea. When I save the note in Firebase it is being saved with newline (\\n) character
Use white-space: pre-line; CSS property.
white-space: pre-line;
As write in Mozzila Doc for pre-line value:
pre-line
Sequences of white space are collapsed. Lines are broken at newline characters, at , and as necessary to fill line boxes.