Skip to content

Commit

Permalink
feat: add saber-plugin-search (#366)
Browse files Browse the repository at this point in the history
* feat: saber-plugin-local-search

* fix: only add valid pages

* use global public url

Co-Authored-By: Koyuki (EGOIST) <[email protected]>

* shorten syntax

* rename plugin to `saber-plugin-search`

* feat: add multiple adapter support

* make it more low-level

* strip html tags

* Add LICENSE

* tweaks

* docs: update readme
  • Loading branch information
krmax44 authored and egoist committed Aug 22, 2019
1 parent bcd0693 commit aaf2d63
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/saber-plugin-search/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,10 @@ const options = {
name: 'excerpt',
weight: 0.4
}
]
],
shouldSort: true // sorts the results by score
}

const fuse = new Fuse(database, options)
const matchedResults = fuse.search(keyword)
```
Expand Down

0 comments on commit aaf2d63

Please sign in to comment.