Skip to content

Commit

Permalink
updated docs to reflect new :state param
Browse files Browse the repository at this point in the history
  • Loading branch information
bvaughn committed Jan 29, 2016
1 parent 31faacc commit 1337196
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docs/reduxSearch.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const store = compose(
reduxSearch({
// Other configuration goes here...
resourceIndexes: {
books: ({ resources, indexDocument }) => {
books: ({ resources, indexDocument, state }) => {
resources.forEach(book => {
indexDocument(book.id, book.name)
book.authors.forEach(
Expand All @@ -35,3 +35,5 @@ const store = compose(
```

You can use the `indexDocument` callback to index your collection on as many fields as you would like. Indexing is done in a web-worker thread and so it won't block the UI.

A `state` object is also specified in case your custom index needs to access any other part of your application store.

0 comments on commit 1337196

Please sign in to comment.