rafgraph / react-router-hash-link

Hash link scroll functionality for React Router
https://react-router-hash-link.rafgraph.dev
MIT License
732 stars 62 forks source link

Should be an option to disable focus management #89

Open Haraldson opened 2 years ago

Haraldson commented 2 years ago

I’m working on a Table Of Contents feature for EditorJS, and as part of this I’m scrolling to heading blocks in the editor, which have their own event listeners and focus handling. As part of this handling, attempts to control elements controlled by the editor seem to throw errors.

So, while I appreciate the efforts to improve accessibility etc., the focus management can also be in the way in more advanced contexts, and it’d be nice to have a way to disable it.

Thoughts?

rafgraph commented 2 years ago

I’d be open to this as a boolean prop. Feel free to make a pr and I’ll take a look. It should be a fairly straightforward addition.