0

I want to add a new line to textAngular WYSIWYG editor.

I'm using \n, but its not working

<text-angular ng-model="htmlContent" name="demo-editor" placeholder="sample text \n testttt"></text-angular>

enter image description here

Or

<text-angular ng-model="htmlContent" name="demo-editor" placeholder="sample text <br/> testttt"></text-angular>

enter image description here

Hetdev
  • 1,425
  • 2
  • 21
  • 29

1 Answers1

0

First of all, you have to add this html class to your css

.placeholder-text::before {
  white-space: pre;
}

Then you can set the text with '\a'.

<text-angular ng-model="htmlContent" name="demo-editor" placeholder="sample text \a testttt"></text-angular>

enter image description here

Hetdev
  • 1,425
  • 2
  • 21
  • 29