Optimize trbody, get rid of more each_with_index