Total Complexity | 5 |
Complexity/F | 1.25 |
Lines of Code | 15 |
Function Count | 4 |
Duplicated Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | $(function () { |
||
2 | highlightRow(); |
||
3 | $('.share-link').click(function() { |
||
4 | setTimeout(function(){ highlightRow(); }, 200); |
||
5 | |||
6 | }); |
||
7 | |||
8 | function highlightRow() { |
||
9 | const anchor = window.location.hash.substr(1); |
||
10 | $('tr').removeClass('highlight'); |
||
11 | if (anchor !== '') { |
||
12 | $('#' + anchor).addClass('highlight'); |
||
13 | } |
||
14 | } |
||
15 | }) |