🔥 Get 650+ Tech Books and Courses for $3/m for 3 months

jQuery clone table row and make empty

Sam Deering
Share

Quick jQuery snippet to clone a table row (and make empty) appended to a table.

var clonedRow = $('tbody tr:first').clone();
clonedRow.find('input').val('');
$(this).prev().find($('table tbody')).append(clonedRow);