Live data from Hacker News

Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

news.ycombinator.com

91–97 of 97 posts

Re: Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

#91
post #85

Discourse (forum) used to hijack Ctrl+F (Command+F) shortcut which makes it super irritating! Not sure if they have changed that.

That is only done if you are in a topic page where the amount of posts is higher than 20 replies.

In that case Ctrl+f is redirected to a search that is scoped to the current topic and can search it all.

Other pages don't have the search hijacked, and of they do you can press Ctrl+f twice to open the browser search.

Re: Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

#92
post #87

You can paste something like this into your javascript console: setInterval(function() { window.scrollTo(0, document.body.scrollHeight); }, 2000); That will scroll continuously, so you can let it run for a while and then do ctrl-F. It might take a while but you can do something else. I've used it successfully many times (usually when I wanted to scrape the DOM for some reason or another, rather than just do a search)…

Or just put something heavy on your keyboard's "End" key :)

Ha yeah that works, if you don't want to do anything else on your computer for a while as it does its thing....

Re: Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

#93
post #80

You can paste something like this into your javascript console: setInterval(function() { window.scrollTo(0, document.body.scrollHeight); }, 2000); That will scroll continuously, so you can let it run for a while and then do ctrl-F. It might take a while but you can do something else. I've used it successfully many times (usually when I wanted to scrape the DOM for some reason or another, rather than just do a search)…

I've tried this twice in the last year or so: once on twitter and once on dropbox. Neither time did it work. It _seemed_ that ctrl+f would not find anything that was not visible +/- a screen height or two. I couldn't tell if it was a shortcoming of Firefox (unlikely IMO) or both sites tried to be clever about dynamically unloading content when it was outside the view window (more likely).

Seems to be a Firefox thing. Works fine on Chromium browsers, only finds stuff near the top in Firefox.

Re: Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

#94
I’ve been finding it increasingly difficult to find blog templates that don’t do infinite scrolling with no way to turn it off. It’s not impossible, and most blog themes still have an option to turn it off if they’re included, but I’ve noticed it’s increasingly difficult to find themes without it. It seems to be the cool thing to do. But for setting up a static blog using the template, it’s a non-starter. Plus for all the aforementioned reasons: CTRL+F, linking to content, following a link and then going back, SEO (although some do SSR — still this is a non-starter for a statically published blog that just generates the pages using the theme)...

Re: Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

#95
I haven't tested if this works for Reddit for some sites, if you use Opera, somehow they show you an 'old' version of the site that doesn't have auto-scrolling. I'm not sure why - perhaps it's because there's some kink in Opera that doesn't support it, but it's worth a try?

Re: Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

#96
post #39

Infinite scroll is one of those things that needs to die.

Nope, I love infinite scroll as a user. I even use extensions to add it to paginated websites. I wish those websites had infinite scroll as default or as an option cause infinite scroll extensions can be jankey. Not saying there aren't bad implementations of infinite scroll out there, those do need to die off, but they aren't that common.

I hate it as a user, it needs to die because it makes my user experience so much worse. I've never seen a not-broken implementation. Suddenly, the end key cannot take me to the bottom of the page, using the browsers native search function (which I will always chose over an in-page alternative) cannot do its thing, I can no longer get an idea of how far along I am in the list, and I cannot do a quick visual scan of many items because dragging the scrollbar does not behave naturally. Page up and page down is all but broken.

A compromise may be a browser option that one can set globally to indicate whether one wants pagination (and how many results per page) or infini-scroll.

Re: Ask HN: How do you search for $string if a webpage “supports” infinite scroll?

#97
post #91
post #85

Discourse (forum) used to hijack Ctrl+F (Command+F) shortcut which makes it super irritating! Not sure if they have changed that.

That is only done if you are in a topic page where the amount of posts is higher than 20 replies. In that case Ctrl+f is redirected to a search that is scoped to the current topic and can search it all. Other pages don't have the search hijacked, and of they do you can press Ctrl+f twice to open the browser search.

last i tried discourse was in 2016. things may have changed.
Post reply on HN