It was this comment what made me realize #:~:text= in the URL isn't some custom, per-site JS hack or a weird way to name your anchors, but actual standard[0] way to link to a text on any page.
[0] https://developer.mozilla.org/en-US/docs/Web/URI/Reference/F...
Chrome and derivatives have a "Copy link to highlight" context menu, which also adds some text surrounding the highlight, but I removed that since it only has a single occurrence.