Comments (9)
Seems to be finding it for me. The odd thing is that it also somehow is matching the "Automating mobile web apps" section as well...hmmm.
from slate.
This is what I see on Chrome. It looks like a bug to me.
from slate.
Hmm, that is the behavior I would expect, it just filters the sections down to the sections containing the search query, but the the optimal behavior...it would be nice if the view skipped down to the first search result. I'll open a separate feature request for this.
from slate.
Automating mobile web apps
doesn't contain the string write docs
so I think it should be hidden? I'm expecting only How to write docs
to be displayed on the side bar.
from slate.
Hmm. I think Automating mobile web apps
contains both the words "write" and "docs", and so the fuzzy searching is picking it up. At least, that's my guess.
from slate.
Yes, I think that's the bug. It's doing a search for write AND docs
when the expected search is "write docs"
the complete literal string. Compare the current behavior to the Google chrome built in search.
If I changed the search behavior to match the Google chrome search, would you accept a pull request?
from slate.
Hmm, I'd rather not make the search quite as blunt as the Google Chrome search...it seems that Lunr gives us a score
property, what if we just sorted the sections by that, so the best-matching section appears first? That would make "how to write docs" appear at the very top, and the less-well-matching results appear farther down the page.
from slate.
I was just about to comment. Enforcing a minimum score resolves the issue.
2 results! all.js:3143
Object {ref: "how-to-write-docs", score: 0.4679618817634447} all.js:3145
Object {ref: "automating-mobile-web-apps", score: 0.00003974502238349404}
The unexpected matches have a very low score.
from slate.
Perfect! If you find a nice threshold, I would be glad to accept a pull request that sets a minimum.
from slate.
Related Issues (20)
- Success redirect
- EMFILE, possible file handler leak
- Difficulty implementing on Windows machine HOT 1
- Difficulty implementing on Windows machine in both approach (ruby & docker as well) HOT 3
- Search function not finding results HOT 3
- [email protected]
- lang specific blockquotes weird behavior. HOT 2
- no implicit conversion of Hash into Integer HOT 1
- bundle exec middleman server: have error
- diff ruby version HOT 1
- Build with Docker should create a build folder with current owner user instead of root HOT 3
- unable to configure the slate set up in windows HOT 1
- UniqueHeadCounter not working when deploying with Docker HOT 1
- Update Invoice API documentation HOT 2
- editable re-render cause the cursor to be brought forward in composing events.
- ddd
- i got /usr/bin/env: ‘bash\r’: No such file or directory when i run the container
- Incorrect Section Highlighted in TOC When Near End Of Page
- Window middleman command fail
- REPORT A BUG!!! HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from slate.