Skip to content

Instantly share code, notes, and snippets.

@jlong
Created July 6, 2012 14:52
Show Gist options
  • Save jlong/3060618 to your computer and use it in GitHub Desktop.
Save jlong/3060618 to your computer and use it in GitHub Desktop.
diff --git a/source/docs/index.html b/source/docs/index.html
index da07196..e81e6ac 100644
--- a/source/docs/index.html
+++ b/source/docs/index.html
@@ -45,7 +45,7 @@ sidebar: false
$('.articles li').each(function() {
var li = $(this), a = li.find('a');
- if (expression.test(li.text()) || expression.test(a.attr('data-search-meta'))) {
+ if ((li.text().search(expression) > -1) || (('' + a.attr('data-search-meta')).search(expression) > -1)) {
a.html(a.text().replace(expression, "<mark>$1</mark>"));
li.show();
results = true;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment