From cd1969f17742d9d72b1502cb2a6baa62e8be5c3e Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Mon, 3 Jun 2019 20:19:17 -0400 Subject: Let's call it version 1.0. --- public/js/posts.lunr.js | 23 ----------------------- 1 file changed, 23 deletions(-) delete mode 100644 public/js/posts.lunr.js (limited to 'public/js/posts.lunr.js') diff --git a/public/js/posts.lunr.js b/public/js/posts.lunr.js deleted file mode 100644 index bea1216..0000000 --- a/public/js/posts.lunr.js +++ /dev/null @@ -1,23 +0,0 @@ -let documents = [{ - "name": "Lunr", - "text": "Like Solr, but much smaller, and not as bright." -}, { - "name": "React", - "text": "A JavaScript library for building user interfaces." -}, { - "name": "Lodash", - "text": "A modern JavaScript utility library delivering modularity, performance & extras." -}]; - -function search() { - let searchIndex = lunr(function() { - this.ref("name") - this.field("text") - - documents.forEach(function(doc) { - this.add(doc) - }, this) - }); - - return searchIndex.search("bright"); -} -- cgit v1.2.3