Textarea Autoheight
HTML
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<textarea placeholder="Test Me"></textarea>
CSS
textarea {
resize: none;
font-size: 13px;
padding: 10px;
height:38px;
min-height: 38px;
width: 400px;
box-sizing: border-box;
overflow: hidden;
}
JavaScript
$('textarea').on('input', function() {
var oldHeight = $(this).outerHeight();
$(this).outerHeight(38);
var newHeight = this.scrollHeight + 38;
$(this).outerHeight(oldHeight);
if (newHeight !== oldHeight)
$(this).animate({height: newHeight}, 80);
});