优化侧边栏点击事件js性能

This commit is contained in:
Argo-Lenovo 2016-11-19 13:12:03 +08:00
parent 9f01d7a88a
commit ff7517cfd2
1 changed files with 1 additions and 1 deletions

View File

@ -20,7 +20,7 @@
$('#websiteFooter').text($('#footer').val());
$('#sidebar .sub-menu > a').click(function () {
$('#sidebar').on('click', 'a', function () {
var o = ($(this).offset());
diff = 300 - o.top;
if (diff > 0)