hanzi
hanzi copied to clipboard
Add exact lookup type for dictionarySearch
For my purposes, I needed a more exact lookup functionality.
For example:
console.log(hanzi.dictionarySearch('小孩', 'only')) gave

console.log(hanzi.dictionarySearch('小孩')) gave

But now this console.log(hanzi.dictionarySearch('小孩', 'exact')) gives

Codecov Report
Merging #60 into master will increase coverage by
0.04%. The diff coverage is100%.
@@ Coverage Diff @@
## master #60 +/- ##
==========================================
+ Coverage 87.77% 87.81% +0.04%
==========================================
Files 15 15
Lines 548 550 +2
Branches 91 92 +1
==========================================
+ Hits 481 483 +2
Misses 55 55
Partials 12 12
| Impacted Files | Coverage Δ | |
|---|---|---|
| lib/dictionary.js | 88.06% <100%> (+0.07%) |
:arrow_up: |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing dataPowered by Codecov. Last update 8b80e6d...234d8b1. Read the comment docs.