Check out example codes for "niklas von hertzen html2canvas textarea capture only one line". It will help you in understanding the concepts better.

Code Example 1

<p contenteditable="true" placeholder="write here" style="border: 1px solid #000000;width=100px;height:300px"></p>

Learn ReactJs, React Native from akashmittal.com