lunr.js is an advanced client-side content (JSON) indexing and querying
library:
http://blog.new-bamboo.co.uk/2013/02/26/full-text-search-in-your-browser
Might be overkill but TW is about the only place I can imagine this kind of
think making sense.
Whadyathink Jeremy?
Excerpt:
With the index defined JSON documents can be added:
1 var documents = [{ 2 id: 1, 3 title: 'Twelfth Night', 4 body:
'If music be the food of love, play on' 5 }, { 6 id: 2, 7 title:
'Macbeth', 8 body: 'When shall we three meet again, In thunder, lightning,
or in rain?' 9 }, {*10* id: 3,11 title: 'Richard III',12 body: 'Now
is the winter of our discontent, Made glorious summer by this sun of York;'13
}]14 15 documents.forEach(function (document) {16 index.add(document)17 })
Searching is equally simple:
1 index.search('love') -> [{ ref: 1, score: 0.7854 }]
--
You received this message because you are subscribed to the Google Groups
"TiddlyWikiDev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/tiddlywikidev?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.