philc / vimium

The hacker's browser.
https://chrome.google.com/webstore/detail/vimium/dbepggeogbaibhgnhhndojpepiihcmeb
MIT License
23.36k stars 2.48k forks source link

Feature Request - ID hints #3560

Open OriR opened 4 years ago

OriR commented 4 years ago

Similarly to link hints, it might be helpful to get hints of ids in a page.

Some examples of this would be Wikipedia and MDN. All of the headings there have ids on them, which if you use them in the url (as a hash parameter) you'll automatically scroll to the right one.

A lot of sites use the § character as an anchor link to utilize that behavior, and in that case we can hit f and use that link.

For the sites that don't offer this, it would be nice to have ID hints as an alternative.

The behavior would be the same as link hints and it'd look for ids within the document and highlight them - it can filter out ids of form elements or container elements as they're not "navigable".

It could also support hint filtering just like link hints.

gdh1995 commented 4 years ago

Maybe Display #Anchors can be used with Vimium to implement this idea - I found this in https://github.com/philc/vimium/issues/3603.