rahs
rahs

Reputation: 1899

Formatting options in textArea element in Angular Material

Angular 5

I want to provide features such as bullet points, formatting text, etc. in a text area element of my page. Is there any way to do this while using Angular material elements?

Upvotes: 0

Views: 1270

Answers (1)

mittal bhatt
mittal bhatt

Reputation: 1009

You can't do that but there is another way. delete the textarea.use contenteditable="true".using contenteditable="true" you can edit in your textarea section.

'<section id="textarea" contenteditable="true">
<ul>
    <li>List item here</li>
    <li>List item here</li>
    <li>List item here</li>
    <li>List item here</li>
</ul>

</section>'

Upvotes: 1

Related Questions