Re: [whatwg] New feature: better integration with browser find interface

On Wed, 29 Oct 2014, Peter Kasting wrote:
> On Tue, Oct 28, 2014 at 10:59 AM, Ian Hickson <> wrote:
> > > 
> > > - telling UA that it should retry the search because content has 
> > > been changed/rendered/modified
> > >
> > > The last is important because for web application which dynamically 
> > > render the content, after search has already find matches on the 
> > > page, if content is changed, browsers do not retry the search. This 
> > > is the most evident with browsers which allow "highlight all" 
> > > feature, like Google Chrome.
> >
> > This is just a bug in the browsers.
> If browsers had to retry open "find"s every time the page content 
> changed, then leaving one's find bar open could have very large negative 
> performance effects, even if the browser focused only on the modified 
> pieces of the page.

How large?

On Thu, 30 Oct 2014, Robert O'Callahan wrote:
> It seems possible to me:
> 1) You can do it lazily, during idle time (though some apps don't have any)
> 2) You can do it incrementally
> 3) You can start with the visible part of the page

You can also use a rate-limitting and back-off strategy -- only update 
find every second or so at most, and if the user hasn't interacted with 
the page, do it even less often.

There's no reason to do it every nanosecond as the page is modified.

> Having said that, it would be complex enough I don't know if it would ever
> be worth implementing.

In its most basic implementation, where you only do it every few seconds 
and only if the user has interacted with the page recently, it seems 
relatively simple, especially if you don't bother with the incremental 

As someone who deals in large pages and searches in those pages a lot, I 
find the lack of dynamic find-in-page to be a regular nuissance, FWIW.

Ian Hickson               U+1047E                )\._.,--....,'``.    fL       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Thursday, 30 October 2014 18:40:44 UTC