3 ms·
I've noticed CTRL+F is occasionally broken these days (match found, but not visible) and was thinking perhaps its the time for browser vendors to introduce a ne
by dzhiurgis 10y ago
I've noticed CTRL+F is occasionally broken these days (match found, but not visible) and was thinking perhaps its the time for browser vendors to introduce a new way to search pages for users?
a.i. CTRL+F to search current state, then click on option to search in the way that website implements and then perhaps use global search (optional).
I'm sure graybeards will argue this breaks web in some way, so pardon my ignorance.
- happyslobro 10y agoThis drives me nuts. I see two modes of breakage: 1. When a search engine indexes something dynamic that has changed by the time I visit the page, and 2. When some part of the UI is in the DOM, but not visible. #1 could probably be solved by judicious use of <aside> on the part of developers, and by SEO penalties imposed on sites that update indexed content without inviting a crawler over to see it within a timely manner. As for #2, I avoid this problem in React by imposing a rule in the coding standards: Do not hide elements. Omit them from a render function when you don't need them. This idea of keeping a stash of recyclable elements complicates that a little. What browser vendors could do to help, is identify non-visible elements and omit them from the Ctrl-F search index. They are probably already identifying invisible elements in order to prune them from the renderer's view of the DOM tree. I wonder how hard it is to submit a pull request to Chromium?