Sha256: 2f2d03de4f96c27ed486a55997eafa2af6eba6a81b5f83a01c2385c2408cf2d4
Contents?: true
Size: 375 Bytes
Versions: 22
Compression:
Stored size: 375 Bytes
Contents
GitDocs.search = { highlight : function(query) { $('.results dl dd').each(function(idx, el) { var result = $(el).text().replace(new RegExp(query, 'ig'), function($0) { return"<strong>" + $0 + "</strong>"; }); $(el).html(result); }); } }; $(document).ready(function() { var query = $('.results').data("query"); GitDocs.search.highlight(query); });
Version data entries
22 entries across 22 versions & 2 rubygems