Hacker News new | past | comments | ask | show | jobs | submit login

There's also:

That we want well known standards like CTRL + F in a browser to be hijacked and replaced by default with a custom search experience that's a lot worse than a browser's search.

Try CTRL + F'ing on Stripe's documentation: https://stripe.com/docs/api/plans




Often those custom search implementations are there because the "page" you're on isn't really a page, the scrollbar is fake, text is inserted and removed automatically as you "scroll", and as a result of all that Ctrl-F doesn't actually work by default. Of course you could argue that these heavyweight designs are a bad idea in the first place, but that's a trickier discussion. I think it's rare that web sites hijack Ctrl-F when leaving it alone is an option -- but I could be wrong about that.


>Of course you could argue that these heavyweight designs are a bad idea in the first place, but that's a trickier discussion.

I would argue that, and I don't think it's a particularly tricky discussion; If your site design subverts the normal, expected behaviour and functionality of the browser to such an extreme degree, then you created a poor user experience.


On Chrome, you can hit CTRL + G, which does the same as CTRL + F, but is not hookable by web sites


Thanks for that, I didn't know it! It seems that also F3 works, and in fact CTRL+G is alias of F3, and both work in Firefox as well.

The only issue is that in Firefox, it is only equivalent for the first search; once you close the bottom bar, subsequent F3/CTRL-G just do "find next occurrence" and do not display the bar anymore. Chrome always displays the search input on the other hand.

Edit: since talking shortcuts, in Firefox ' (apostrophe) is like CTRL-F but searches only hyperlinks (and you can cycle through in case of multiple matches with F3/CTRL-G) which is extremely useful for quickly navigating pages via keyboard only.


Ctrl + G certainly is hookable[0], folks just rarely know that it's an alias for 'find'. If you REALLY want the browser's search, in Chrome, you can use the mouse to open the menu and choose "Find". You could also use any keyboard shortcut that focuses the URL bar (so keyboard events are no longer sent to the page) and press Ctrl-f then.

0: In Google Sheets, for example, Ctrl-g opens the JS-driven find bar, or, if it's already open, advances the match.


Somewhat related: The last version of Chromium said "Press Alt+F and then X" instead of Ctrl-Shift-Q when I tried to quit it using that key combo.

Unfortunately, Alt+F is trivially overridable by web pages (Twitch.tv in this case -- to move to the search bar), so that doesn't really work.

Chromium devs have no idea what the impact of their decisions are... and judging by the issue trackers they don't care.


I kinda want to burn down the world after reading this comment. How did we let computing get to be such a garbage fire?


Holy shit I had no idea! I was tired of Chrome's bookmark manager hijacking CTRL + F. I'll use CTRL + G from now on!


Luckily, Stripe is polite enough to allow users to fall back to default search with another tap of ctrl+f.


I would second the discouragement to override this behaviour. Although they have handled it well with a CTRL + F + F again bringing it back to native search behaviour.


I don't see an issue, their widget allows me to go back to my default ctrl-f by pressing it again.


The main issue is it's on by default and it's a vastly inferior search UI to what everyone has been using to search / skim a page since browsers existed.


Ace editor does this too - possibly because large documents might not all actually be in the DOM.


In Stripe's case, the docs are all rendered server side and are viewable without Javascript.

I'm not sure if you can hook into the native CTRL + F search tool and see what a user typed (my gut says no way there's an API for that), so I guess Stripe just wanted to track as much information as possible on what people are searching for, even if it makes the user experience a lot worse.


(I am an engineer who worked on this feature)

The docs are indeed viewable without JS[0] (in a limited way) but the default experience relies on JS to render text.

We don't render all content on the page at once for performance reasons, which is (as a sibling speculated) the driving reason for overriding cmd+f/ctrl+f by default.

I hope to write an engineering blog post soon about how we build the Stripe api docs, with some focus on the performance and UX tradeoffs at play here.

[0] https://stripe.com/docs/api?javascript=false


This. Stripe's overengineered, custom Ctrl+F is unusable on Firefox. they could've just put a search bar for their own "search" feature instead of breaking the Ctrl+F browser convention that we're so familiar with.


For me it shows the option to use the native search by pressing CMD+F a second time.


oof, that's completely unusable on Firefox for me -- it seems like the loading is blocking my keyboard input or something.

    Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:67.0) Gecko/20100101 Firefox/67.0


(I have worked on this feature) Thanks for reporting – I can reproduce and will take a look at fixing shortly. Sorry for the troubles!


Why don’t you fix it by removing it. Most web users don’t want native features overridden. It’s obnoxious. It breaks UI and UX paradigms.

Whoever thought it was a good idea should get shot out of a canon.

Decisions like this are why I do not support adding more functionality into web browsers. Most web developers have proven to be inept and incompetent. As demonstrated by this dumpster fire of a “feature”


Can you fix this issue by not hijacking keyboard shortcuts needlessly?


Thanks for taking a look!


What does that do?

(Mobile, cannot invoke keyboard on page, JS disabled.)

And behaviour may change.

Just tell us.


Instead of being able to hit CTRL + F and immediately search and then have your browser highlight matches and decorate your scrollbar with where results are (so you can skim), they decided to override that behavior and introduce their own take on what search results should look like.

One that takes multiple seconds to get a response on a search and it's all contained in a tiny modal dialog box that has no skimmability and when you click one of the results it does a new page load to bring you to the results. Stripe is usually a superb developer experience. Truthfully I have no idea how it ended up in production as a default option.


It's something like "Go to Resource" in code editors. Tries to navigate to methods / things based on what you type




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: