Consider search index optimizations
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- javascript, r
- Domain
- documentation, search
Research direction
Start with inst/BS5/assets/pkgdown.js at lines 96–102 and read the linked Fuse.js index-parameter documentation. Reproduce the geom_boxplot search on the generated ggplot2 documentation, then evaluate location, threshold, and distance settings. Done means the relevant reference page ranks above unrelated pages for this query without breaking general search behavior.
Written by the indexing model from the issue text.
Description
I recently went looking for the geom_boxplot docs on the ggplot2 site. Searching for geom_boxplot and hitting return took me to the top hit, a page on quantile regression unrelated to what I wanted.
This is because geom_boxplot appears near the top of that page, higher than the first mention of geom_boxplot on the actual reference page.
My read of the fusejs docs suggest this could be easily addressed with some optimization of the parameters used to build the index. In particular, instead of setting ignoreLocation: true here, we could tune location, threshold, and distance index parameters. The docs provide a good example for this:
For example, consider the string "Fuse.js is a powerful, lightweight fuzzy-search library, with zero dependencies". Searching for the pattern "zero" would not match anything, even though it occurs in the string. The reason is that with the above defaults, for it to be considered a match it would have to be within 60 characters away from the expected location 0. However, "zero" appears at index 62.
- Dominant language
- R
- Stars
- 775
- Forks
- 355
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from r-lib/pkgdown
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
-
Difficulty 1/5 Under an hour Newbie friendliness 92/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
r-lib/pkgdepends#485 · 3 comments ·
-
Difficulty 1/5 Under an hour Newbie friendliness 92/100
-
beginners blocker
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enviPathR OpenBuild Error Build OK Build Warning policies-accepted pre-review precheck-passed
Difficulty 1/5 Under an hour Newbie friendliness 84/100
Bioconductor/BiocContributions#207 · 6 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
datacarpentry/semester-biology#1255 ·