Skip to content

Commit 089bc40

Browse files
authored
Update README.md
1 parent 266ea02 commit 089bc40

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

README.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@
33
[Tokenization](#tokenization) |
44
[Stemming](#stemming) |
55
[Stop Words](#stop-words) |
6-
[TF-IDF ranking](#tf-idf-ranking)
6+
[Search Index](#configuring-the-search-index) |
7+
[Index Stragegy](#configuring-the-index-strategy)
78

89
# Js Search: client-side search library
910

@@ -144,7 +145,7 @@ appears in the document but is offset by the frequency of the word in the corpus
144145
some words (e.g. and, or, the) appear more frequently than others.
145146

146147
By default Js Search supports TF-IDF ranking but this can be disabled for performance reasons if it is not required. You
147-
can specify an alternate [`ISearchIndex`](https://github.com/wuweiweiwu/js-search/blob/master/source/SearchIndex/SearchIndex.js)
148+
can specify an alternate [`ISearchIndex`](https://github.com/bvaughn/js-search/blob/master/source/SearchIndex/SearchIndex.js)
148149
implementation in order to disable TF-IDF, like so:
149150

150151
```javascript
@@ -160,13 +161,17 @@ search.searchIndex = new JsSearch.UnorderedSearchIndex();
160161

161162
There are three index strategies packaged with `js-search`.
162163

163-
`PrefixIndexStrategy` indexes for prefix searches
164+
`PrefixIndexStrategy` indexes for prefix searches.
164165
(e.g. the term "cat" is indexed as "c", "ca", and "cat" allowing prefix search lookups).
165166

166167
`AllSubstringsIndexStrategy` indexes for all substrings. In other word "c", "ca", "cat", "a", "at", and "t" all match "cat".
167168

168169
`ExactWordIndexStrategy` indexes for exact word matches. For example "bob" will match "bob jones".
169170

171+
By default Js Search supports prefix indexing but this can be disabled if it is not required. You
172+
can specify an alternate [`IIndexStrategy`](https://github.com/bvaughn/js-search/blob/master/source/IndexStrategy/IndexStrategy.js)
173+
implementation in order to disable prefix indexing, like so:
174+
170175
```javascript
171176
// default
172177
search.indexStrategy = new JsSearch.PrefixIndexStrategy();

0 commit comments

Comments
 (0)