Sometimes there may be such a demand, a vertical input box, enter the information, text is arranged from top to bottom;
(However, when the moving end with a rotation swiper or does not function, instead of textarea input)
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Document</title> <style> .abc{ width: 50px; height: 400px; border: 2px solid red; box-sizing: border-box; padding: 10px; font-size: 30px; -webkit-user-select:text; } </style> </head> <body> <div class="abc" contenteditable=true>请输入你的名字</div> </body> </html>