Chrome textarea limits the number of characters that can be entered if newlines are included.

<textarea
    placeholder="Please enter reason for rejection."
    maxlength="10"
    >
</textarea>
Copy the code

The test results

The browser Carriage returns take up several characters
Chrome 46.0.2490.86 (64 – bit) 2
Chrome 46.0.2490.86 m 2
ie 11 1
edge 1
Firefox 42.0 1

The resources

  • Issue 252613 – chromium – textarea maxlength attribute does not count the correct string length