1
Fork 0

rustdoc: hardcode each header as a link.

This avoids having to include JS in the guide/tutorial/manual pages just
to get the headers being links. The on-hover behaviour showing the
little section marker § is preserved, because that gives a useful hint
that the heading is a link.
This commit is contained in:
Huon Wilson 2014-03-08 01:24:54 +11:00
parent f22c96cc88
commit 7a70ec1ba6
4 changed files with 17 additions and 14 deletions

View file

@ -600,10 +600,4 @@
initSearch(searchIndex);
$.each($('h1, h2, h3'), function(idx, element) {
if ($(element).attr('id') != undefined) {
$(element).append('<a href="#' + $(element).attr('id') + '" ' +
'class="anchor"> § </a>');
}
});
}());